Johannes Schindelin <Johannes.Schindelin@xxxxxx> writes: >> Johannes Schindelin <Johannes.Schindelin@xxxxxx> writes: >> >> > It is allowed to call >> > >> > $ git --git-dir=../ --work-tree=. bla >> > >> > when you really want to. In this case, you are both in the git directory >> > and in the working tree. > ... > There are files in that directory (and all of its subdirectories) of a > certain type, which are the only ones which are human generated, and > therefore precious. I like to add them, and inspect them, with > > git --git-dir=$HOME/x.git add > > and > > git --git-dir=$HOME/x.git diff I understand the --git-dir=$HOME/x.git to keep track of something in $HOME/foo/bar example. But that is not the issue you described in the original message. I was asking about this (which is the way I read your original message): $ GIT_DIR=$HOME/x.git git init $ mkdir $HOME/x.git/workroot $ cd $HOME/x.git/workroot $ git --git-dir=../ --work-tree=. That is, $HOME/x.git/ is the GIT_DIR that has HEAD, index and refs/, and you are keeping track of contents whose rootlevel is at $HOME/x.git/workroot - 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