Commit d766ca8f authored by Paul Eggert's avatar Paul Eggert
Browse files

Chatter when changes Git configuration

* (git_config): New function.  Use it instead of ‘git config’.
parent 3b734e12
......@@ -220,17 +220,32 @@ echo timestamp > src/ || exit
## Configure Git, if using Git.
if test -d .git && (git status -s) >/dev/null 2>&1; then
# Like 'git config NAME VALUE', but verbose on change and exit on failure.
git_config ()
ovalue=`git config --get "$name"` && test "$ovalue" = "$value" || {
echo "${Configuring_git}git config $name '$value'"
git config "$name" "$value" || exit
Configuring_git='Configuring git...
# Check hashes when transferring objects among repositories.
git config transfer.fsckObjects true || exit
git_config transfer.fsckObjects true
# Configure 'git diff' hunk header format.
git config 'diff.elisp.xfuncname' \
'^\(def[^[:space:]]+[[:space:]]+([^()[:space:]]+)' || exit
git config 'diff.texinfo.xfuncname' \
'^@node[[:space:]]+([^,[:space:]][^,]+)' || exit
git_config 'diff.elisp.xfuncname' \
git_config 'diff.texinfo.xfuncname' \
# Install Git hooks.
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