Creating aliases for iTerm 2 that work during ssh I use numerous aliases set at a given UNIX environment. For example my current fish shell under OSX have these below


gm -> git merge
dk -> docker kill


and so on. 

Now the challenge is I use iTerm 2 for connecting to various remote sessions and I wish these aliases work seamlessly on all sessions. 

Is there a way to push these aliases into a global context so that iTerm 2 will input the original command upon detecting these aliases. 

i.e if I hit gm + enter in any iTerm window it must issue git merge to the remote session.
If you use oh-my-zsh, you will want to place those in ~/.zshrc

vi ~/.zshrc

.
.
.
# Example aliases
# alias zshconfig="mate ~/.zshrc"
# alias ohmyzsh="mate ~/.oh-my-zsh"
alias work="cd ~/Lucas/local-sites/"