<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/builtin/clone.c, branch v2.5.2</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://git.shady.money/git/atom?h=v2.5.2</id>
<link rel='self' href='https://git.shady.money/git/atom?h=v2.5.2'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/'/>
<updated>2015-08-25T23:09:17Z</updated>
<entry>
<title>Merge branch 'jk/guess-repo-name-regression-fix' into maint</title>
<updated>2015-08-25T23:09:17Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2015-08-25T23:09:17Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=52f6893d356fd04ba350e5b7dd468b2181844521'/>
<id>urn:sha1:52f6893d356fd04ba350e5b7dd468b2181844521</id>
<content type='text'>
"git clone $URL" in recent releases of Git contains a regression in
the code that invents a new repository name incorrectly based on
the $URL.  This has been corrected.

* jk/guess-repo-name-regression-fix:
  clone: use computed length in guess_dir_name
  clone: add tests for output directory
</content>
</entry>
<entry>
<title>clone: use computed length in guess_dir_name</title>
<updated>2015-08-10T18:01:05Z</updated>
<author>
<name>Jeff King</name>
<email>peff@peff.net</email>
</author>
<published>2015-08-10T15:48:22Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=db2e220447f7b02278d64417c8f05f73710f5b8b'/>
<id>urn:sha1:db2e220447f7b02278d64417c8f05f73710f5b8b</id>
<content type='text'>
Commit 7e837c6 (clone: simplify string handling in
guess_dir_name(), 2015-07-09) changed clone to use
strip_suffix instead of hand-rolled pointer manipulation.
However, strip_suffix will strip from the end of a
NUL-terminated string, and we may have already stripped some
characters (like directory separators, or "/.git"). This
leads to commands like:

  git clone host:foo.git/

failing to strip the ".git".

We must instead convert our pointer arithmetic into a
computed length and feed that to strip_suffix_mem, which will
then reduce the length further for us.

It would be nicer if we could drop the pointer manipulation
entirely, and just continually strip using strip_suffix. But
that doesn't quite work for two reasons:

  1. The early suffixes we're stripping are not constant; we
     need to look for is_dir_sep, which could be one of
     several characters.

  2. Mid-way through the stripping we compute the pointer
     "start", which shows us the beginning of the pathname.
     Which really give us two lengths to work with: the
     offset from the start of the string, and from the start
     of the path. By using pointers for the early part, we
     can just compute the length from "start" when we need
     it.

Signed-off-by: Jeff King &lt;peff@peff.net&gt;
Acked-by: Sebastian Schuberth &lt;sschuberth@gmail.com&gt;
Signed-off-by: Patrick Steinhardt &lt;ps@pks.im&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'ss/clone-guess-dir-name-simplify'</title>
<updated>2015-07-13T21:00:28Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2015-07-13T21:00:28Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=721f5bb8968ed6a6ec126fe28f679c17a6998e87'/>
<id>urn:sha1:721f5bb8968ed6a6ec126fe28f679c17a6998e87</id>
<content type='text'>
Code simplification.

* ss/clone-guess-dir-name-simplify:
  clone: simplify string handling in guess_dir_name()
</content>
</entry>
<entry>
<title>clone: simplify string handling in guess_dir_name()</title>
<updated>2015-07-09T21:21:29Z</updated>
<author>
<name>Sebastian Schuberth</name>
<email>sschuberth@gmail.com</email>
</author>
<published>2015-07-09T18:24:08Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=7e837c6477b59cc51756e241ccfee76068e5e379'/>
<id>urn:sha1:7e837c6477b59cc51756e241ccfee76068e5e379</id>
<content type='text'>
Signed-off-by: Sebastian Schuberth &lt;sschuberth@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'jk/clone-dissociate' into maint</title>
<updated>2015-06-16T21:33:52Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2015-06-16T21:33:52Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=37d6f933dff7d5c295870c85399f5fd22072643a'/>
<id>urn:sha1:37d6f933dff7d5c295870c85399f5fd22072643a</id>
<content type='text'>
Code clean-up.

* jk/clone-dissociate:
  clone: reorder --dissociate and --reference options
  clone: use OPT_STRING_LIST for --reference
</content>
</entry>
<entry>
<title>Merge branch 'jk/clone-dissociate'</title>
<updated>2015-06-11T16:29:52Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2015-06-11T16:29:52Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=82b416e063d9b1497eac78a8deaad340d251f1dc'/>
<id>urn:sha1:82b416e063d9b1497eac78a8deaad340d251f1dc</id>
<content type='text'>
Code clean-up.

* jk/clone-dissociate:
  clone: reorder --dissociate and --reference options
  clone: use OPT_STRING_LIST for --reference
</content>
</entry>
<entry>
<title>Merge branch 'mh/clone-verbosity-fix' into maint</title>
<updated>2015-06-05T19:00:08Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2015-06-05T19:00:08Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=a3821a1ae5580ac9788d866c292376070d3e5133'/>
<id>urn:sha1:a3821a1ae5580ac9788d866c292376070d3e5133</id>
<content type='text'>
Git 2.4 broke setting verbosity and progress levels on "git clone"
with native transports.

* mh/clone-verbosity-fix:
  clone: call transport_set_verbosity before anything else on the newly created transport
</content>
</entry>
<entry>
<title>clone: reorder --dissociate and --reference options</title>
<updated>2015-05-27T19:37:39Z</updated>
<author>
<name>Jeff King</name>
<email>peff@peff.net</email>
</author>
<published>2015-05-21T04:16:04Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=14f8b9b494c990188a4dfe772c384b1be5f8351b'/>
<id>urn:sha1:14f8b9b494c990188a4dfe772c384b1be5f8351b</id>
<content type='text'>
These options are intimately related, so it makes sense to
list them nearby in the "-h" output (they are already
adjacent in the manpage).

Signed-off-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>clone: use OPT_STRING_LIST for --reference</title>
<updated>2015-05-27T19:37:28Z</updated>
<author>
<name>Jeff King</name>
<email>peff@peff.net</email>
</author>
<published>2015-05-21T04:15:19Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=8ade009c952b2977508d6d88aacc290c645125d2'/>
<id>urn:sha1:8ade009c952b2977508d6d88aacc290c645125d2</id>
<content type='text'>
Not only does this save us having to implement a custom
callback, but it handles "--no-reference" in the usual way
(to clear the list).

The generic callback does copy the string, which we don't
technically need, but that should not hurt anything.

Signed-off-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'mh/clone-verbosity-fix'</title>
<updated>2015-05-22T19:41:56Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2015-05-22T19:41:56Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=5bf66689d5a4ddc4ce7b3b88a15f6bcf6a0c13fa'/>
<id>urn:sha1:5bf66689d5a4ddc4ce7b3b88a15f6bcf6a0c13fa</id>
<content type='text'>
Git 2.4 broke setting verbosity and progress levels on "git clone"
with native transports.

* mh/clone-verbosity-fix:
  clone: call transport_set_verbosity before anything else on the newly created transport
</content>
</entry>
</feed>
