How to unset aliases set by Oh My Zsh

14 June 2018   0 comments   Linux, MacOSX

I use Oh My Zsh and I highly recommend it. However, it sets some aliases that I don't want. In particular, there's a plugin called git.plugin.zsh (located in ~/.oh-my-zsh/plugins/git/git.plugin.zsh) that interfers with a global binary I have in $PATH. So when I start a shell the executable gg becomes...:

▶ which gg
gg: aliased to git gui citool

That overrides /usr/local/bin/gg which is the one I want to execute when I type gg. To unset that I can run...:

unset gg

▶ which gg
/usr/local/bin/gg

To override it "permanently", I added, to the end of ~/.zshrc:

# This unsets ~/.oh-my-zsh/plugins/git/git.plugin.zsh
# So my /usr/local/bin/gg works instead
unalias gg

Now whenever I start a new terminal, it defaults to the gg in /usr/local/bin/gg instead.

Comments

Your email will never ever be published


Related posts

Previous:
How to NOT start two servers on the same port 11 June 2018
Next:
The best grep tool in the world; ripgrep 19 June 2018
Related by Keyword:
How I found out where a bash alias was set up 09 May 2018
gg - A prototype to rule Git, GitHub and Bugzilla 06 May 2016
gg - wrapping git-grep 11 August 2009
www aliases set up 01 November 2005
Related by Text:
jQuery and Highslide JS 08 January 2008
I'm back! Peterbe.com has been renewed 05 June 2005
Anti-McCain propaganda videos 12 August 2008
Ever wondered how much $87 Billion is? 04 November 2003
Guake, not Yakuake or Yeahconsole 23 January 2010