Useful Oh-My-Zsh plugins
May 3rd, 2015
Warning: This post is 9 years old. Some of this information may be out of date.
I've been using zsh as a replacement shell on both my Ubuntu laptop and my work Macbook for a while. Coupled with Robby Russell's excellent Oh-My-Zsh https://github.com/robbyrussell/oh-my-zsh and it's plethora of zsh plugins I now have a powerful shell with many new features.
Oh-My-Zsh describes itself as a 'community driven framework for managing your zsh configuration' and comes with lots of zsh plugins (189 currently) but none are enabled by default. Some zsh plugins are tailored for your specific operating system whilst others are aimed at helping improve developers workflow. Wether you're using Ruby, Python, PHP or Javascript as your main language or you're a systems administrator, there will be a plugin to help. The full list of zsh plugins is available at https://github.com/robbyrussell/oh-my-zsh/wiki/Plugins, Here are the zsh plugins I'm currently using:
command-not-found
Only for use with Ubuntu and openSUSE. If a command isn't found in your $PATH it wull use the system command-not-found
package to find it.
composer
If you're a PHP developer then I'm sure you use Composer a lot. This plugin provides shortcuts to some of Composer's commands:
c composer
csu composer self-update
cu composer update
ci composer install
ccp composer create-project
cget installs composer on the current path
git
I'm sure everyone knows git
now, right? This plugin provides aliases to the most commonly used git commands:
g git
gsh git status
gl git pull
gp git push
gcmsg git commit -m
gcm git checkout master
gb git branch
ga git add
gm git merge
A full list of the git plugin aliases can be found at https://github.com/robbyrussell/oh-my-zsh/wiki/Plugin:git
npm
Simply adds autocompletion to the npm command. Type npm
(space) and press tab to get autocompletion for the available npm commands. Note Be prepared for a long wait when using autocompletion with npm search
.
osx
The OSX plugin provides aliases and functionality for those using Apple's OSX OS.
tab open the current directory in a new tab
pfd return the path of the frontmost Finder window
pfs return the current Finder selection
cdf cd to the current Finder directory
pushdf pushd to the current Finder directory
quick-look quick Look a specified file
man-preview open a specified man page in Preview
trash move a specified file to the Trash
sudo
This is one of those plugins that becomes a must have after a short period of using it. Simply hitting ESC
twice puts sudo
in front of the current command, or the last one if your cli is empty. Genius!
vagrant
This plugin adds autocomplete help to the vagrant commands. For example, entering vagrant box
followed by tab
shows help for management of vagrant boxes.
Previous →
Install Beanstalkd on Ubuntu 12.04