I\'m wondering if there\'s a way to avoid having to type the word git
at the beginning of every Git command.
It would be nice if there was a way to use the
After
while read -erp "*git*${PS1@P}" cmd rest; do
if _=`git help $cmd 2>&-`
then eval git $cmd "$rest"
else eval $cmd "$rest"
fi
done
every command we type is by default interpreted as a Git command
if it looks like one, otherwise it'll be interpreted as-is, so you can intermix git with other commands, and if you want to use a punned command just prefix it with a backslash, rm foo
would be eval'd as git rm foo
, but \rm foo
would run the plain rm
command. ^d out as usual to end it.