configure: add build directory to gitignore (#2543)

This commit is contained in:
Michael Stapelberg 2016-11-07 11:49:26 -08:00 committed by GitHub
parent 9c6a21f2d4
commit 841118e5f8
1 changed files with 9 additions and 0 deletions

View File

@ -146,6 +146,15 @@ else
print_BUILD_MANS=no
fi
git_dir=`git rev-parse --git-dir 2>/dev/null`
if test -n "$git_dir"; then
srcdir=`dirname "$git_dir"`
exclude_dir=`pwd | sed "s,^$srcdir,,g"`
if ! grep -q "^$exclude_dir" "$git_dir/info/exclude"; then
echo "$exclude_dir" >> "$git_dir/info/exclude"
fi
fi
echo \
"--------------------------------------------------------------------------------
build configured: