1git-annex-proxy(1) General Commands Manual git-annex-proxy(1)
2
3
4
6 git-annex-proxy - safely bypass direct mode guard
7
9 git annex proxy -- git cmd [options]
10
12 Only useful in a direct mode repository, this runs the specified git
13 command with a temporary work tree, and updates the working tree to
14 reflect any changes staged or committed by the git command.
15
16 For example, to revert the most recent change that was committed to the
17 repository:
18
19 git annex proxy -- git revert HEAD
20
21 To check out a past version of the repository:
22
23 git annex proxy -- git checkout HEAD^^
24
25 To rename a directory:
26
27 git annex proxy -- git mv mydir newname
28
29 To commit the changes to a specific file, first use git annex add to
30 stage the changes in the index, and then proxy a commit:
31
32 git annex add myfile
33 git annex proxy -- git commit myfile -m foo
34
35 The temporary work tree that the git command is run in is set up by
36 checking out all files that are in the index, and copying (or hard
37 linking) any unstaged files from the real work tree. Since the git com‐
38 mand is run using this temporary work tree, it won't see eg, local mod‐
39 ifications to files. So, it probably is not useful to proxy a command
40 like "git add". However, you can use the proxy with any git command
41 you like, as long as you think about how it will interact with the tem‐
42 porary work tree.
43
45 git-annex(1)
46
47 git-annex-direct(1)
48
50 Joey Hess <id@joeyh.name>
51
52 git-annex-proxy(1)