aboutsummaryrefslogtreecommitdiff
path: root/git-sh-setup.sh
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2010-03-04 22:25:37 -0800
committerJunio C Hamano <gitster@pobox.com>2010-03-04 22:25:37 -0800
commit801bad3ba4eb5014d402201c85c61a969436adf0 (patch)
tree647c5370bb49b784401910fc500727a8bf3e49a0 /git-sh-setup.sh
parentce5044df2a29c4f4979089b072aad43bccb3b9fd (diff)
parentab62677b1424d4e53cf222c973b841d3dada4cf3 (diff)
downloadgit-801bad3ba4eb5014d402201c85c61a969436adf0.tar.gz
git-801bad3ba4eb5014d402201c85c61a969436adf0.tar.xz
Merge branch 'gf/maint-sh-setup-nongit-ok' into maint
* gf/maint-sh-setup-nongit-ok: require_work_tree broken with NONGIT_OK
Diffstat (limited to 'git-sh-setup.sh')
-rwxr-xr-xgit-sh-setup.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/git-sh-setup.sh b/git-sh-setup.sh
index d56426dd3..5e22440ae 100755
--- a/git-sh-setup.sh
+++ b/git-sh-setup.sh
@@ -128,7 +128,7 @@ cd_to_toplevel () {
}
require_work_tree () {
- test $(git rev-parse --is-inside-work-tree) = true ||
+ test "$(git rev-parse --is-inside-work-tree 2>/dev/null)" = true ||
die "fatal: $0 cannot be used without a working tree."
}