Re: [RFC/PATCH] clone: add `--shallow-submodules` flag

2016-03-14 Thread Junio C Hamano
Stefan Beller writes: > you'd fetch as usual without moving the anchor point. You could have > options like > > $ git fetch --recurse-submodules[=label/pattern] > --unshallow-submodules[=label/pattern] > ... > So the first one should be shallowed after fetch, but the

Re: [RFC/PATCH] clone: add `--shallow-submodules` flag

2016-03-14 Thread Stefan Beller
On Sat, Mar 12, 2016 at 11:29 AM, Junio C Hamano wrote: > Stefan Beller writes: > >> Why is it interesting for submodules but not for standard repositories? >> >> If I clone a repository without submodules, it is also not recorded >> that I cloned with an

Re: [RFC/PATCH] clone: add `--shallow-submodules` flag

2016-03-12 Thread Junio C Hamano
Stefan Beller writes: > Why is it interesting for submodules but not for standard repositories? > > If I clone a repository without submodules, it is also not recorded > that I cloned with an explicit depth=1. If you fetch, you may end up with > a deeper history as git fetch

Re: [RFC/PATCH] clone: add `--shallow-submodules` flag

2016-03-11 Thread Stefan Beller
On Fri, Mar 11, 2016 at 4:41 PM, Junio C Hamano wrote: > Stefan Beller writes: > >> When creating a shallow clone of a repository with submodules, the depth >> argument does not influence the submodules, i.e. the submodules are done >> as non-shallow

Re: [RFC/PATCH] clone: add `--shallow-submodules` flag

2016-03-11 Thread Junio C Hamano
Stefan Beller writes: > When creating a shallow clone of a repository with submodules, the depth > argument does not influence the submodules, i.e. the submodules are done > as non-shallow clones. It is unclear what the best default is for the > depth of submodules of a

[RFC/PATCH] clone: add `--shallow-submodules` flag

2016-03-11 Thread Stefan Beller
When creating a shallow clone of a repository with submodules, the depth argument does not influence the submodules, i.e. the submodules are done as non-shallow clones. It is unclear what the best default is for the depth of submodules of a shallow clone, so we need to have the possibility to do