Re: [Discuss] soften warning message after cloning "void"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Feb 18, 2015 at 4:25 PM, Junio C Hamano <gitster@xxxxxxxxx> wrote:
> Checking out a random branch is absolutely the worst thing you can
> do. Personally, I would think that the best thing you can do is to
> educate your users not to clone from a void. Create some history
> that is worth sharing, and then push into an empty repository.

Users are dumb.

Consider a website like GitHub where you create a repository on a a
remote server. It is initialized as an empty repo. They now want to
clone that empty repo to work with it:

  git clone https://example.com/foo
  cd foo
  .... hack hack
  git commit -a -m "Foo is awesome!"
  git push

This works from git-core servers because the ref advertisement tells
the client its an empty repo and its OK to checkout HEAD from nothing
and its all fine.

This fails from a JGit server because the ref advertisement for an
empty repository differs and disagrees with the format used by
git-core. The result is a confused client spewing an odd checkout
message.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]