21 GIT_DIR=$(git-rev-parse --git-dir) || exit
23 if [ -f "$GIT_DIR/info/exclude" ]; then
24 global_exclude="--exclude-from=$GIT_DIR/info/exclude"
26 for i in $(git-ls-files --others \
27 $global_exclude --exclude-per-directory=.gitignore \
30 [ "$verbose" ] && echo " $i"
31 [ "$show_only" ] || git-update-index --add -- "$i" || exit