Can I pass arguments to the alias of a Git command?
I have some alias in Git config, like so:
rb1 = rebase -i HEAD~1
rb2 = rebase -i HEAD~2
rb3 = reb
I wrote this function "grb" to do Git interactive rebase on a Mac, so I can say grb 5
to show my last 5 commits:
function grb {
git rebase -i HEAD~$1
}
The top answer on this page does not work for me.
To see my .bash_profile
and all other Git aliases I use on my Mac:
https://github.com/rayning0/bash_profile/blob/master/.bash_profile#L146