Revision a87e8be2aece466e3f41dfde81c80709e1d56cd3 authored by Linus Torvalds on 14 July 2005, 02:45:26 UTC, committed by Linus Torvalds on 14 July 2005, 02:45:26 UTC
.. and does a "git-upload-pack" on demand.
1 parent 85c414b
Raw File
git
#!/bin/sh
cmd="$1"
shift
if which git-$cmd-script >& /dev/null
then
	exec git-$cmd-script "$@"
fi

if which git-$cmd >& /dev/null
then
	exec git-$cmd "$@"
fi

alternatives=($(echo $PATH | tr ':' '\n' | while read i; do ls $i/git-*-script 2> /dev/null; done))

echo Git command "'$cmd'" not found. Try one of
for i in "${alternatives[@]}"; do
	echo $i | sed 's:^.*/git-:   :' | sed 's:-script$::'
done | sort | uniq
back to top