What does -stdlayout do in git svn clone?

I just noticed this question about recovering from a clone without --stdlayout. I did not find the documentation for this flag - what does it do?

+17
git svn git-svn
Mar 19 '11 at 10:33
source share
2 answers

Subversion has no concept of branch or tag. Instead, they are usually modeled by simply copying the contents of the repository into a directory.

In order for git svn to recognize branches and tags and the main branch ("trunk"), you need to explicitly specify where to find them using --tags (or -t ), --branches (or -b ) and --trunk (or -t ).

However, many Subversion repositories follow the standard conventions set forth in the Subversion book, --trunk=/trunk --branches=/branches --tags=/tags . --stdlayout (or -s ) encodes this convention, so you don't need to pass the same arguments every time you clone a Subversion repository.

You can find this information on the git-svn(1) manual page, which you can access on Unix using man git-svn and regardless of the operating system through the built-in Git help system with git help svn . All Git man pages are also available on Kernel.Org, and they are usually the first search result when searching for git-svn(1) .

+34
Mar 19 '11 at 10:40
source share
β€” -

--stdlayout ( -s ) tells git-svn that the folders in /branches should be imported as branches, and the folders in /tags are snapshots of the status of the project and should be imported as tags. The master branch will be set to /trunk .

This is equivalent to --trunk=trunk --tags=tags --branches=branches

+11
Mar 19 '11 at 10:38
source share



All Articles