Clear or disable aliases in zsh

You can use unalias with -m option:

unalias -m '*'

to delete all defined aliases


If you don't want any of oh-my-zsh's aliases, but you want to keep other aliases, you can save the aliases before loading oh-my-zsh

save_aliases=$(alias -L)

and restore them afterwards.

eval $save_aliases; unset save_aliases

If you want to remove all aliases at some point, you can use unalias -m '*' (remove all aliases matching *, i.e. all of them).

If you absolutely hate aliases and don't want to ever see one, you can make the alias builtin inoperative: unalias -m '*'; alias () { : }. Or you can simply turn off alias expansion with setopt no_aliases.


If you only want to remove the git aliases, I recommend one of the following two choices:

  1. Change ~/.oh-my-zsh/plugins/git/git.plugin.zsh by removing all the aliases at the bottom

  2. Make a copy of that plugin (recommended location: ~/.oh-my-zsh/custom/plugins/git-noalias/git-noalias.plugin.zsh), edit that copy to not have the aliases, and then change your ~/.zshrc to do plugins=(git-noalias) instead of plugins=(git).

This will give you all the benefits of the plugin (I'm not sure what they are but they may be related to the automatic Git status/branch information displayed within Git folders) without the aliases.