git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH 2/4] Recommend use of structure options for git svn.

From
Sebastian Leske <sebastian.leske@sleske.name>
Date
Nov 21, 2012, 07:13 UTC
Message-ID
<a4de87e8d09c26221eff116c3209b0a3606dfc21.1353691892.git.Sebastian.Leske@sleske.name>
In-Reply-To
<b115a546fa783b4121d118bb8fdb9270443f90fa.1353691892.git.Sebastian.Leske@sleske.name>

Document that when using git svn, one should usually either use the directory structure options to import branches as branches, or only import one subdirectory. The default behaviour of cloning all branches and tags as subdirectories in the working copy is usually not what the user wants.

Signed-off-by: Sebastian Leske <sebastian.leske@sleske.name>
---
 Documentation/git-svn.txt |   10 ++++++++++
 1 file changed, 10 insertions(+)
diff --git a/Documentation/git-svn.txt b/Documentation/git-svn.txt
index 482d60d..928a961 100644
--- a/Documentation/git-svn.txt
+++ b/Documentation/git-svn.txt
@@ -871,6 +871,16 @@ already dcommitted.  It is considered bad practice to --amend commits
 you've already pushed to a remote repository for other users, and
 dcommit with SVN is analogous to that.
 
+When cloning an SVN repository, if none of the options for describing
+the repository layout is used (--trunk, --tags, --branches,
+--stdlayout), 'git svn clone' will create a git repository with
+completely linear history, where branches and tags appear as separate
+folders in the working copy.  For projects with many branches this will
+lead to a working copy many times larger than just the trunk.  It is
+recommended to either use the the options for trunk / tag / branch
+directory, or to only clone the trunk (or a subdirectory of the
+trunk).
+
 When using multiple --branches or --tags, 'git svn' does not automatically
 handle name collisions (for example, if two branches from different paths have
 the same name, or if a branch and a tag have the same name).  In these cases,
-- 
1.7.10.4
Previous: Sebastian LeskeNext: Michael J Gruber
Message 2 of 8 in “git-svn: Document branches with at-sign(@).”
  1. 1/4 git-svn: Document branches with at-sign(@).Sebastian Leske, Nov 18, 2012
  2. 2/4 Recommend use of structure options for git svn.Sebastian Leske, Nov 21, 2012
  3. Michael J GruberNov 28, 2012
  4. 3/4 git-svn: Expand documentation for --follow-parentSebastian Leske, Nov 23, 2012
  5. Michael J GruberNov 28, 2012
  6. 4/4 git-svn: Note about tags.Sebastian Leske, Nov 23, 2012
  7. Michael J GruberNov 28, 2012
  8. Michael J GruberNov 28, 2012

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.