Commit 91109821 authored by Paul Eggert's avatar Paul Eggert

Port to Git 2.4

Problem reported by Michael Brand in:
* (git_config): Don't assume that git rev-parse
groks --git-common-dir.
parent c8109d9c
......@@ -277,8 +277,10 @@ git_config ()
# Get location of Git's common configuration directory. For older Git
# versions this is just '.git'. Newer Git versions support worktrees.
test -e .git && git_common_dir=`git rev-parse --git-common-dir 2>/dev/null` ||
{ test -e .git &&
git_common_dir=`git rev-parse --no-flags --git-common-dir 2>/dev/null` &&
test -n "$git_common_dir"
} || git_common_dir=.git
# Check hashes when transferring objects among repositories.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment