git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [BUG] git-init does not respect existing separate-git-dir
@ 2013-08-29 12:39 Ximin Luo
  2013-08-29 13:04 ` Duy Nguyen
  0 siblings, 1 reply; 5+ messages in thread
From: Ximin Luo @ 2013-08-29 12:39 UTC (permalink / raw)
  To: git

[-- Attachment #1: Type: text/plain, Size: 609 bytes --]

It should not be necessary to re-specify --separate-git-dir when re-initialising a git repo.

$ git init --separate-git-dir ../repo
Initialized empty Git repository in /home/infinity0/tmp/repo/

$ git init
/home/infinity0/tmp/wtree/.git/refs: Not a directory
1

One big motivation is so "git init" can be a good "fire-and-forget" invocation that should work anywhere. Currently, one has to do "git init --separate-git-dir $(git rev-parse --git-dir)" which is a lot less elegant.

(Please CC me as I am not subscribed.)

-- 
GPG: 4096R/1318EFAC5FBBDBCE
git://github.com/infinity0/pubkeys.git


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 897 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2013-09-03 18:14 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-08-29 12:39 [BUG] git-init does not respect existing separate-git-dir Ximin Luo
2013-08-29 13:04 ` Duy Nguyen
2013-08-29 17:12   ` Junio C Hamano
2013-08-31  1:04     ` [PATCH] Make setup_git_env() resolve .git file when $GIT_DIR is not specified Nguyễn Thái Ngọc Duy
2013-09-03 18:14       ` Junio C Hamano

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).