Re: git add -A fails in empty repository since 1.8.5

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

 



Junio C Hamano <gitster@xxxxxxxxx> writes:

> It could be argued that a "git add [<any option>] .", with an
> explicit "." given by the end-user, that is run in an empty
> directory may be an error worth reporting.

But what we have right now is really weird:

# setup repo with one empty dir:
$ rm -fr test
$ git init test
Initialized empty Git repository in /tmp/test/.git/
$ cd test
$ mkdir foo

$ git add .
fatal: pathspec '.' did not match any files

=> The one we're discussing.

$ git add foo

=> No error when an empty directory other than . is given.

$ cd foo
$ git add .

=> No error either for "git add ." when not at the root of the repo.

-- 
Matthieu Moy
http://www-verimag.imag.fr/~moy/
--
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]