This commit is contained in:
https://www.google.com/accounts/o8/id?id=AItOawm4or5sJLWB0evPKp70Q2OND-JmFPnOkLA 2011-08-09 13:02:32 +00:00 committed by admin
parent 065e1a507b
commit 1e934c29d6

View file

@ -1,28 +1,29 @@
git-annex does not take into account the --git-dir and --work-tree command line options (while they can be useful when scripting). git-annex does not take into account the --git-dir and --work-tree command line options (while they can be useful when scripting).
> mkdir /tmp/test > mkdir /tmp/test
> cd /tmp/test > cd /tmp/test
> git init > git init
Initialized empty Git repository in /tmp/test/.git/ Initialized empty Git repository in /tmp/test/.git/
> git annex init test > git annex init test
init test ok init test ok
> touch foo > touch foo
> cd > cd
> git --git-dir=/tmp/test/.git --work-tree=/tmp/test annex add foo > git --git-dir=/tmp/test/.git --work-tree=/tmp/test annex add foo
git-annex: Not in a git repository. git-annex: Not in a git repository.
regular git add works: regular git add works:
> git --git-dir=/tmp/test/.git --work-tree=/tmp/test add foo
> git --git-dir=/tmp/test/.git --work-tree=/tmp/test status > git --git-dir =/tmp/test/.git --work-tree=/tmp/test add foo
# On branch master > git --git-dir=/tmp/test/.git --work-tree=/tmp/test status
# # On branch master
# Initial commit #
# # Initial commit
# Changes to be committed: #
# (use "git rm --cached <file>..." to unstage) # Changes to be committed:
# # (use "git rm --cached <file>..." to unstage)
# new file: foo #
# # new file: foo
#
git-annex version: 3.20110702 git-annex version: 3.20110702