From 61f36a79da11accfaaab986bf65453ed30fdbd9f Mon Sep 17 00:00:00 2001 From: Tuomas Suutari Date: Fri, 14 Aug 2009 11:11:58 +0300 Subject: git-svn.txt: Fix location of parent argument The note about interoperating in different timezones and such is about localtime argument, not parent. Signed-off-by: Tuomas Suutari Acked-by: Eric Wong --- Documentation/git-svn.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Documentation/git-svn.txt') diff --git a/Documentation/git-svn.txt b/Documentation/git-svn.txt index 22a0389f1e..1812890a7e 100644 --- a/Documentation/git-svn.txt +++ b/Documentation/git-svn.txt @@ -102,9 +102,6 @@ COMMANDS Store Git commit times in the local timezone instead of UTC. This makes 'git log' (even without --date=local) show the same times that `svn log` would in the local timezone. - ---parent;; - Fetch only from the SVN parent of the current HEAD. + This doesn't interfere with interoperating with the Subversion repository you cloned from, but if you wish for your local Git @@ -112,6 +109,9 @@ repository to be able to interoperate with someone else's local Git repository, either don't use this option or you should both use it in the same local timezone. +--parent;; + Fetch only from the SVN parent of the current HEAD. + --ignore-paths=;; This allows one to specify a Perl regular expression that will cause skipping of all matching paths from checkout from SVN. -- cgit v1.2.3 From 6111b934991f3ea670ac2442806c976defc7b61c Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Sun, 15 Nov 2009 18:57:16 -0800 Subject: git svn: attempt to create empty dirs on clone+rebase We parse unhandled.log files for empty_dir statements and make a best effort attempt to recreate empty directories on fresh clones and rebase. This should cover the majority of cases where users work off a single branch or for projects where branches do not differ in empty directories. Since this cannot affect "normal" git commands like "checkout" or "reset", so users switching between branches in a single working directory should use the new "git svn mkdirs" command after switching branches. Signed-off-by: Eric Wong --- Documentation/git-svn.txt | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'Documentation/git-svn.txt') diff --git a/Documentation/git-svn.txt b/Documentation/git-svn.txt index 1812890a7e..db00ed43b7 100644 --- a/Documentation/git-svn.txt +++ b/Documentation/git-svn.txt @@ -320,6 +320,13 @@ Any other arguments are passed directly to 'git log' directories. The output is suitable for appending to the $GIT_DIR/info/exclude file. +'mkdirs':: + Attempts to recreate empty directories that core git cannot track + based on information in $GIT_DIR/svn//unhandled.log files. + Empty directories are automatically recreated when using + "git svn clone" and "git svn rebase", so "mkdirs" is intended + for use after commands like "git checkout" or "git reset". + 'commit-diff':: Commits the diff of two tree-ish arguments from the command-line. This command does not rely on being inside an `git svn -- cgit v1.2.3 From ce45a45f24cc7b3ccc7f6ebcd0025559b4421bda Mon Sep 17 00:00:00 2001 From: Thomas Rast Date: Mon, 16 Nov 2009 11:15:17 +0100 Subject: Document git-svn's first-parent rule git-svn has the following rule to detect the SVN base for its operations: find the first git-svn-id line reachable through first-parent ancestry. IOW, git log --grep=^git-svn-id: --first-parent -1 Document this, as it is very important when using merges with git-svn. Signed-off-by: Thomas Rast --- Documentation/git-svn.txt | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'Documentation/git-svn.txt') diff --git a/Documentation/git-svn.txt b/Documentation/git-svn.txt index db00ed43b7..4cdca0d874 100644 --- a/Documentation/git-svn.txt +++ b/Documentation/git-svn.txt @@ -742,6 +742,16 @@ merges you've made. Furthermore, if you merge or pull from a git branch that is a mirror of an SVN branch, 'dcommit' may commit to the wrong branch. +If you do merge, note the following rule: 'git svn dcommit' will +attempt to commit on top of the SVN commit named in +------------------------------------------------------------------------ +git log --grep=^git-svn-id: --first-parent -1 +------------------------------------------------------------------------ +You 'must' therefore ensure that the most recent commit of the branch +you want to dcommit to is the 'first' parent of the merge. Chaos will +ensue otherwise, especially if the first parent is an older commit on +the same SVN branch. + 'git clone' does not clone branches under the refs/remotes/ hierarchy or any 'git svn' metadata, or config. So repositories created and managed with using 'git svn' should use 'rsync' for cloning, if cloning is to be done -- cgit v1.2.3 From a65f3c202b8771f79117b566946d9cb3348f6fad Mon Sep 17 00:00:00 2001 From: Igor Mironov Date: Tue, 12 Jan 2010 03:22:27 +1100 Subject: git-svn: document --username/commit-url for branch/tag [ew: shortened subject] Signed-off-by: Igor Mironov Acked-by: Eric Wong --- Documentation/git-svn.txt | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'Documentation/git-svn.txt') diff --git a/Documentation/git-svn.txt b/Documentation/git-svn.txt index 4cdca0d874..8dbf9d1cb2 100644 --- a/Documentation/git-svn.txt +++ b/Documentation/git-svn.txt @@ -239,6 +239,19 @@ discouraged. where is the name of the SVN repository as specified by the -R option to 'init' (or "svn" by default). +--username;; + Specify the SVN username to perform the commit as. This option overrides + configuration property 'username'. + +--commit-url;; + Use the specified URL to connect to the destination Subversion + repository. This is useful in cases where the source SVN + repository is read-only. This option overrides configuration + property 'commiturl'. ++ + git config --get-all svn-remote..commiturl ++ + 'tag':: Create a tag in the SVN repository. This is a shorthand for 'branch -t'. -- cgit v1.2.3 From 3e18ce1ac3034b1562ec748523aa7636e1b58b52 Mon Sep 17 00:00:00 2001 From: Jay Soffian Date: Sat, 23 Jan 2010 03:30:00 -0500 Subject: git-svn: allow UUID to be manually remapped via rewriteUUID In certain situations it may be necessary to manually remap an svn repostitory UUID. For example: o--- [git-svn clone] / [origin svn repo] \ o--- [svnsync clone] Imagine that only "git-svn clone" and "svnsync clone" are made available to external users. Furthur, "git-svn clone" contains only trunk, and for reasons unknown, "svnsync clone" is missing the revision properties that normally provide the origin svn repo's UUID. A git user who has cloned the "git-svn clone" repo now wishes to use git-svn to pull in the missing branches from the "synsync clone" repo. In order for git-svn to get the history correct for those branches, it needs to know the origin svn repo's UUID. Hence rewriteUUID. Signed-off-by: Jay Soffian Acked-by: Eric Wong --- Documentation/git-svn.txt | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) (limited to 'Documentation/git-svn.txt') diff --git a/Documentation/git-svn.txt b/Documentation/git-svn.txt index 8dbf9d1cb2..5df30596de 100644 --- a/Documentation/git-svn.txt +++ b/Documentation/git-svn.txt @@ -62,6 +62,8 @@ COMMANDS Set the 'useSvnsyncProps' option in the [svn-remote] config. --rewrite-root=;; Set the 'rewriteRoot' option in the [svn-remote] config. +--rewrite-uuid=;; + Set the 'rewriteUUID' option in the [svn-remote] config. --username=;; For transports that SVN handles authentication for (http, https, and plain svn), specify the username. For other @@ -629,6 +631,12 @@ svn-remote..rewriteRoot:: the repository with a public http:// or svn:// URL in the metadata so users of it will see the public URL. +svn-remote..rewriteUUID:: + Similar to the useSvmProps option; this is for users who need + to remap the UUID manually. This may be useful in situations + where the original UUID is not available via either useSvmProps + or useSvnsyncProps. + svn.brokenSymlinkWorkaround:: This disables potentially expensive checks to workaround broken symlinks checked into SVN by broken clients. Set this @@ -638,13 +646,14 @@ svn.brokenSymlinkWorkaround:: revision fetched. If unset, 'git svn' assumes this option to be "true". -Since the noMetadata, rewriteRoot, useSvnsyncProps and useSvmProps +Since the noMetadata, rewriteRoot, rewriteUUID, useSvnsyncProps and useSvmProps options all affect the metadata generated and used by 'git svn'; they *must* be set in the configuration file before any history is imported and these settings should never be changed once they are set. -Additionally, only one of these four options can be used per-svn-remote -section because they affect the 'git-svn-id:' metadata line. +Additionally, only one of these options can be used per svn-remote +section because they affect the 'git-svn-id:' metadata line, except +for rewriteRoot and rewriteUUID which can be used together. BASIC EXAMPLES -- cgit v1.2.3 From 075762085c6668f11c4ea165ecec17f69245ef09 Mon Sep 17 00:00:00 2001 From: Jay Soffian Date: Sat, 23 Jan 2010 03:30:01 -0500 Subject: git-svn: allow subset of branches/tags to be specified in glob spec For very large projects it is useful to be able to clone a subset of the upstream SVN repo's branches. Allow for this by letting the left-side of the branches and tags glob specs contain a brace-delineated comma-separated list of names. e.g.: branches = branches/{red,green}/src:refs/remotes/branches/* Signed-off-by: Jay Soffian Acked-by: Eric Wong --- Documentation/git-svn.txt | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'Documentation/git-svn.txt') diff --git a/Documentation/git-svn.txt b/Documentation/git-svn.txt index 5df30596de..99f3c1ea6c 100644 --- a/Documentation/git-svn.txt +++ b/Documentation/git-svn.txt @@ -838,6 +838,22 @@ independent path component (surrounded by '/' or EOL). This type of configuration is not automatically created by 'init' and should be manually entered with a text-editor or using 'git config'. +It is also possible to fetch a subset of branches or tags by using a +comma-separated list of names within braces. For example: + +------------------------------------------------------------------------ +[svn-remote "huge-project"] + url = http://server.org/svn + fetch = trunk/src:refs/remotes/trunk + branches = branches/{red,green}/src:refs/remotes/branches/* + tags = tags/{1.0,2.0}/src:refs/remotes/tags/* +------------------------------------------------------------------------ + +Note that git-svn keeps track of the highest revision in which a branch +or tag has appeared. If the subset of branches or tags is changed after +fetching, then .git/svn/.metadata must be manually edited to remove (or +reset) branches-maxRev and/or tags-maxRev as appropriate. + SEE ALSO -------- linkgit:git-rebase[1] -- cgit v1.2.3 From cb82dbf8be199d114cd220713e4f57574b4636f8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=86var=20Arnfj=C3=B6r=C3=B0=20Bjarmason?= Date: Fri, 7 May 2010 19:50:03 +0000 Subject: git-svn documentation: minor grammar fix MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Use the definite article when talking about a configuration property. Signed-off-by: Ævar Arnfjörð Bjarmason Acked-by: Eric Wong --- Documentation/git-svn.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Documentation/git-svn.txt') diff --git a/Documentation/git-svn.txt b/Documentation/git-svn.txt index 99f3c1ea6c..b09bd9761f 100644 --- a/Documentation/git-svn.txt +++ b/Documentation/git-svn.txt @@ -243,7 +243,7 @@ where is the name of the SVN repository as specified by the -R option to --username;; Specify the SVN username to perform the commit as. This option overrides - configuration property 'username'. + the 'username' configuration property. --commit-url;; Use the specified URL to connect to the destination Subversion -- cgit v1.2.3