In my .bash_profile
, I have the vim
command aliased to /Applications/MacVim.app/Contents/MacOS/Vim
.
For the following line in my .gitconfig
file,
[core]
editor = vim
git runs system vim rather than following the alias specified above. If I manually change it to match the complete path of MacVim's Vim
command above, it works fine.
Is there any way to make .gitconfig
follow the bash alias, rather than having to set the complete MacVim path? (I have all my user config files synchronized across multiple machines, some of which don't run MacVim.)
Aliases are shortcuts for an interactive shell; they are not used by other processes. Just specify the exact path you want in .gitconfig
; you only have to type it once.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With