<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/git.git/git-svn.perl, branch nd/unify-ref-parse</title>
<subtitle>github.com: git/git.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/git.git/'/>
<entry>
<title>Git 2.0: git svn: Set default --prefix='origin/' if --prefix is not given</title>
<updated>2014-04-19T11:30:13+00:00</updated>
<author>
<name>Johan Herland</name>
<email>johan@herland.net</email>
</author>
<published>2013-10-11T12:57:07+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/git.git/commit/?id=fe191fcaa58cb785c804465a0da9bcba9fd9e822'/>
<id>fe191fcaa58cb785c804465a0da9bcba9fd9e822</id>
<content type='text'>
git-svn by default puts its Subversion-tracking refs directly in
refs/remotes/*. This runs counter to Git's convention of using
refs/remotes/$remote/* for storing remote-tracking branches.

Furthermore, combining git-svn with regular git remotes run the risk of
clobbering refs under refs/remotes (e.g. if you have a git remote
called "tags" with a "v1" branch, it will overlap with the git-svn's
tracking branch for the "v1" tag from Subversion.

Even though the git-svn refs stored in refs/remotes/* are not "proper"
remote-tracking branches (since they are not covered by a proper git
remote's refspec), they clearly represent a similar concept, and would
benefit from following the same convention.

For example, if git-svn tracks Subversion branch "foo" at
refs/remotes/foo, and you create a local branch refs/heads/foo to add
some commits to be pushed back to Subversion (using "git svn dcommit),
then it is clearly unhelpful of Git to throw

  warning: refname 'foo' is ambiguous.

every time you checkout, rebase, or otherwise interact with the branch.

The existing workaround for this is to supply the --prefix=quux/ to
git svn init/clone, so that git-svn's tracking branches end up in
refs/remotes/quux/* instead of refs/remotes/*. However, encouraging
users to specify --prefix to work around a design flaw in git-svn is
suboptimal, and not a long term solution to the problem. Instead,
git-svn should default to use a non-empty prefix that saves
unsuspecting users from the inconveniences described above.

This patch will only affect newly created git-svn setups, as the
--prefix option only applies to git svn init (and git svn clone).
Existing git-svn setups will continue with their existing (lack of)
prefix. Also, if anyone somehow prefers git-svn's old layout, they
can recreate that by explicitly passing an empty prefix (--prefix "")
on the git svn init/clone command line.

The patch changes the default value for --prefix from "" to "origin/",
updates the git-svn manual page, and fixes the fallout in the git-svn
testcases.

(Note that this patch might be easier to review using the --word-diff
and --word-diff-regex=. diff options.)

[ew: squashed description of &lt;= 1.9 behavior into manpage]

Suggested-by: Thomas Ferris Nicolaisen &lt;tfnico@gmail.com&gt;
Signed-off-by: Johan Herland &lt;johan@herland.net&gt;
Signed-off-by: Eric Wong &lt;normalperson@yhbt.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
git-svn by default puts its Subversion-tracking refs directly in
refs/remotes/*. This runs counter to Git's convention of using
refs/remotes/$remote/* for storing remote-tracking branches.

Furthermore, combining git-svn with regular git remotes run the risk of
clobbering refs under refs/remotes (e.g. if you have a git remote
called "tags" with a "v1" branch, it will overlap with the git-svn's
tracking branch for the "v1" tag from Subversion.

Even though the git-svn refs stored in refs/remotes/* are not "proper"
remote-tracking branches (since they are not covered by a proper git
remote's refspec), they clearly represent a similar concept, and would
benefit from following the same convention.

For example, if git-svn tracks Subversion branch "foo" at
refs/remotes/foo, and you create a local branch refs/heads/foo to add
some commits to be pushed back to Subversion (using "git svn dcommit),
then it is clearly unhelpful of Git to throw

  warning: refname 'foo' is ambiguous.

every time you checkout, rebase, or otherwise interact with the branch.

The existing workaround for this is to supply the --prefix=quux/ to
git svn init/clone, so that git-svn's tracking branches end up in
refs/remotes/quux/* instead of refs/remotes/*. However, encouraging
users to specify --prefix to work around a design flaw in git-svn is
suboptimal, and not a long term solution to the problem. Instead,
git-svn should default to use a non-empty prefix that saves
unsuspecting users from the inconveniences described above.

This patch will only affect newly created git-svn setups, as the
--prefix option only applies to git svn init (and git svn clone).
Existing git-svn setups will continue with their existing (lack of)
prefix. Also, if anyone somehow prefers git-svn's old layout, they
can recreate that by explicitly passing an empty prefix (--prefix "")
on the git svn init/clone command line.

The patch changes the default value for --prefix from "" to "origin/",
updates the git-svn manual page, and fixes the fallout in the git-svn
testcases.

(Note that this patch might be easier to review using the --word-diff
and --word-diff-regex=. diff options.)

[ew: squashed description of &lt;= 1.9 behavior into manpage]

Suggested-by: Thomas Ferris Nicolaisen &lt;tfnico@gmail.com&gt;
Signed-off-by: Johan Herland &lt;johan@herland.net&gt;
Signed-off-by: Eric Wong &lt;normalperson@yhbt.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>git-svn: Warn about changing default for --prefix in Git v2.0</title>
<updated>2013-10-12T22:30:53+00:00</updated>
<author>
<name>Johan Herland</name>
<email>johan@herland.net</email>
</author>
<published>2013-10-11T12:57:06+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/git.git/commit/?id=f849bb6b3b4ccc7cc1a68f49d6ff1e9c508fdf17'/>
<id>f849bb6b3b4ccc7cc1a68f49d6ff1e9c508fdf17</id>
<content type='text'>
In Git v2.0, we will change the default --prefix for init/clone from
none/empty to "origin/" (which causes SVN-tracking branches to be
placed at refs/remotes/origin/* instead of refs/remotes/*).

This patch warns users about the upcoming change, both in the git-svn
manual page, and on stderr when running init/clone in the "multi-mode"
without providing a --prefix.

Cc: Eric Wong &lt;normalperson@yhbt.net&gt;
Signed-off-by: Johan Herland &lt;johan@herland.net&gt;
Signed-off-by: Eric Wong &lt;normalperson@yhbt.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In Git v2.0, we will change the default --prefix for init/clone from
none/empty to "origin/" (which causes SVN-tracking branches to be
placed at refs/remotes/origin/* instead of refs/remotes/*).

This patch warns users about the upcoming change, both in the git-svn
manual page, and on stderr when running init/clone in the "multi-mode"
without providing a --prefix.

Cc: Eric Wong &lt;normalperson@yhbt.net&gt;
Signed-off-by: Johan Herland &lt;johan@herland.net&gt;
Signed-off-by: Eric Wong &lt;normalperson@yhbt.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>git-svn: fix signed commit parsing</title>
<updated>2013-10-10T06:48:10+00:00</updated>
<author>
<name>Nicolas Vigier</name>
<email>boklm@mars-attacks.org</email>
</author>
<published>2013-09-30T14:46:14+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/git.git/commit/?id=60786bd41a575126c0735c55b46e1d0ee2b358cc'/>
<id>60786bd41a575126c0735c55b46e1d0ee2b358cc</id>
<content type='text'>
When parsing a commit object, git-svn wrongly think that a line
containing spaces means the end of headers and the start of the commit
message. In case of signed commit, the gpgsig entry contains a line with
one space, so "git svn dcommit" will include part of the signature in
the commit message.

An example of such problem :
http://svnweb.mageia.org/treasurer?view=revision&amp;revision=86

This commit changes the regex to only match an empty line as separator
between the headers and the commit message.

Signed-off-by: Nicolas Vigier &lt;boklm@mars-attacks.org&gt;
Reviewed-by: Jonathan Nieder &lt;jrnieder@gmail.com&gt;
Signed-off-by: Eric Wong &lt;normalperson@yhbt.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When parsing a commit object, git-svn wrongly think that a line
containing spaces means the end of headers and the start of the commit
message. In case of signed commit, the gpgsig entry contains a line with
one space, so "git svn dcommit" will include part of the signature in
the commit message.

An example of such problem :
http://svnweb.mageia.org/treasurer?view=revision&amp;revision=86

This commit changes the regex to only match an empty line as separator
between the headers and the commit message.

Signed-off-by: Nicolas Vigier &lt;boklm@mars-attacks.org&gt;
Reviewed-by: Jonathan Nieder &lt;jrnieder@gmail.com&gt;
Signed-off-by: Eric Wong &lt;normalperson@yhbt.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge branch 'vl/typofix'</title>
<updated>2013-06-26T22:07:52+00:00</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2013-06-26T22:07:52+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/git.git/commit/?id=eac9a1a1953bcd89678f649a1efbc8d1a7de9f40'/>
<id>eac9a1a1953bcd89678f649a1efbc8d1a7de9f40</id>
<content type='text'>
* vl/typofix:
  random typofixes (committed missing a 't', successful missing an 's')
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* vl/typofix:
  random typofixes (committed missing a 't', successful missing an 's')
</pre>
</div>
</content>
</entry>
<entry>
<title>random typofixes (committed missing a 't', successful missing an 's')</title>
<updated>2013-06-19T18:31:33+00:00</updated>
<author>
<name>Veres Lajos</name>
<email>vlajos@gmail.com</email>
</author>
<published>2013-06-19T05:37:24+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/git.git/commit/?id=f7e604ed390cec7b20471f9c03bbc507ebfe41c0'/>
<id>f7e604ed390cec7b20471f9c03bbc507ebfe41c0</id>
<content type='text'>
Signed-off-by: Veres Lajos &lt;vlajos@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Veres Lajos &lt;vlajos@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix `git svn` `rebase` &amp; `dcommit` if top-level HEAD directory exist</title>
<updated>2013-06-12T20:38:48+00:00</updated>
<author>
<name>Slava Kardakov</name>
<email>ojab@ojab.ru</email>
</author>
<published>2013-06-05T18:31:27+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/git.git/commit/?id=9926f66fbd4392c9c7c05fae83e80bc12e0be889'/>
<id>9926f66fbd4392c9c7c05fae83e80bc12e0be889</id>
<content type='text'>
When a file (or a directory) called HEAD exists in the working tree,
internal calls git svn makes trigger "did you mean a revision or a
path?" ambiguity check.

    $ git svn rebase
    fatal: ambiguous argument 'HEAD': both revision and filename
    Use '--' to separate paths from revisions, like this:
    'git &lt;command&gt; [&lt;revision&gt;...] -- [&lt;file&gt;...]'
    rev-list --first-parent --pretty=medium HEAD: command returned error: 128

Explicitly disambiguate by adding "--" after the revision.

Signed-off-by: Slava Kardakov &lt;ojab@ojab.ru&gt;
Reviewed-by: Jeff King &lt;peff@peff.net&gt;
Acked-by: Eric Wong &lt;normalperson@yhbt.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When a file (or a directory) called HEAD exists in the working tree,
internal calls git svn makes trigger "did you mean a revision or a
path?" ambiguity check.

    $ git svn rebase
    fatal: ambiguous argument 'HEAD': both revision and filename
    Use '--' to separate paths from revisions, like this:
    'git &lt;command&gt; [&lt;revision&gt;...] -- [&lt;file&gt;...]'
    rev-list --first-parent --pretty=medium HEAD: command returned error: 128

Explicitly disambiguate by adding "--" after the revision.

Signed-off-by: Slava Kardakov &lt;ojab@ojab.ru&gt;
Reviewed-by: Jeff King &lt;peff@peff.net&gt;
Acked-by: Eric Wong &lt;normalperson@yhbt.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>git-svn: introduce --parents parameter for commands branch and tag</title>
<updated>2013-05-20T22:05:54+00:00</updated>
<author>
<name>Tobias Schulte</name>
<email>tobias.schulte@gliderpilot.de</email>
</author>
<published>2013-05-15T20:14:43+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/git.git/commit/?id=f4f4c7fc00e8acf91150c717cf005fc36c1dd120'/>
<id>f4f4c7fc00e8acf91150c717cf005fc36c1dd120</id>
<content type='text'>
This parameter is equivalent to the parameter --parents on svn cp commands
and is useful for non-standard repository layouts.

Signed-off-by: Tobias Schulte &lt;tobias.schulte@gliderpilot.de&gt;
Signed-off-by: Eric Wong &lt;normalperson@yhbt.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This parameter is equivalent to the parameter --parents on svn cp commands
and is useful for non-standard repository layouts.

Signed-off-by: Tobias Schulte &lt;tobias.schulte@gliderpilot.de&gt;
Signed-off-by: Eric Wong &lt;normalperson@yhbt.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>git-svn: added an --include-path flag</title>
<updated>2013-05-09T01:13:36+00:00</updated>
<author>
<name>Paul Walmsley</name>
<email>pjwhams@gmail.com</email>
</author>
<published>2013-05-03T23:10:18+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/git.git/commit/?id=a7b102302ad9495fb4eb5088ffcb09c44a406c06'/>
<id>a7b102302ad9495fb4eb5088ffcb09c44a406c06</id>
<content type='text'>
The SVN::Fetcher module is now able to filter for inclusion as well
as exclusion (as used by --ignore-path). Also added tests, documentation
changes and git completion script.

If you have an SVN repository with many top level directories and you
only want a git-svn clone of some of them then using --ignore-path is
difficult as it requires a very long regexp. In this case it's much
easier to filter for inclusion.

[ew: remove trailing whitespace]

Signed-off-by: Paul Walmsley &lt;pjwhams@gmail.com&gt;
Signed-off-by: Eric Wong &lt;normalperson@yhbt.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The SVN::Fetcher module is now able to filter for inclusion as well
as exclusion (as used by --ignore-path). Also added tests, documentation
changes and git completion script.

If you have an SVN repository with many top level directories and you
only want a git-svn clone of some of them then using --ignore-path is
difficult as it requires a very long regexp. In this case it's much
easier to filter for inclusion.

[ew: remove trailing whitespace]

Signed-off-by: Paul Walmsley &lt;pjwhams@gmail.com&gt;
Signed-off-by: Eric Wong &lt;normalperson@yhbt.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>git-svn: avoid self-referencing mergeinfo</title>
<updated>2013-05-09T01:07:39+00:00</updated>
<author>
<name>Michael Contreras</name>
<email>michael@inetric.com</email>
</author>
<published>2013-03-30T22:06:42+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/git.git/commit/?id=e234ac9d47b6618f7b7338f95f34d0b70782e4cb'/>
<id>e234ac9d47b6618f7b7338f95f34d0b70782e4cb</id>
<content type='text'>
When svn.pushmergeinfo is set, the target branch is included in the
mergeinfo if it was previously merged into one of the source branches.
SVN does not do this.

Remove merge target branch path from resulting mergeinfo when
svn.pushmergeinfo is set to better match the behavior of SVN. Update the
svn-mergeinfo-push test.

[ew: 80 columns]

Signed-off-by: Michael Contreras &lt;michael@inetric.com&gt;
Reported-by: Avishay Lavie &lt;avishay.lavie@gmail.com&gt;
Acked-by: Eric Wong &lt;normalperson@yhbt.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When svn.pushmergeinfo is set, the target branch is included in the
mergeinfo if it was previously merged into one of the source branches.
SVN does not do this.

Remove merge target branch path from resulting mergeinfo when
svn.pushmergeinfo is set to better match the behavior of SVN. Update the
svn-mergeinfo-push test.

[ew: 80 columns]

Signed-off-by: Michael Contreras &lt;michael@inetric.com&gt;
Reported-by: Avishay Lavie &lt;avishay.lavie@gmail.com&gt;
Acked-by: Eric Wong &lt;normalperson@yhbt.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>git-svn: use a lowercase "usage:" string</title>
<updated>2013-02-25T05:30:03+00:00</updated>
<author>
<name>David Aguilar</name>
<email>davvid@gmail.com</email>
</author>
<published>2013-02-24T22:48:38+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/git.git/commit/?id=0b670abd974f50f3bf675d30c093cb7309151ac0'/>
<id>0b670abd974f50f3bf675d30c093cb7309151ac0</id>
<content type='text'>
Make the usage string consistent with Git.

Signed-off-by: David Aguilar &lt;davvid@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Make the usage string consistent with Git.

Signed-off-by: David Aguilar &lt;davvid@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
