diff options
author | Matthias Beyer <mail@beyermatthias.de> | 2015-06-19 19:34:12 +0200 |
---|---|---|
committer | Matthias Beyer <mail@beyermatthias.de> | 2015-06-19 20:15:22 +0200 |
commit | 7a8642806bf156ddad1cc83405f7a2dfeada94c3 (patch) | |
tree | 7c7c4d60faf3898d4c40b4520b5cda31fdd05673 /nix-utils.sh | |
parent | 364b93aec439ff804e1e247fbdc2f1a7062b2dc1 (diff) |
Add __git for executing git in other directory
Diffstat (limited to 'nix-utils.sh')
-rw-r--r-- | nix-utils.sh | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/nix-utils.sh b/nix-utils.sh index 9e50b42..7995e12 100644 --- a/nix-utils.sh +++ b/nix-utils.sh @@ -55,3 +55,7 @@ continue_question() { [[ "${answer}" =~ ^[Yy]$ ]] || return 1 } +__git() { + DIR=$1; shift + explain git --git-dir="$DIR/.git" --work-tree="$DIR" $* +} |