omz tool to dynamically load plugins

This commit is contained in:
nebirhos 2012-03-24 05:14:54 +01:00
commit b326820004
5 changed files with 100 additions and 41 deletions

41
bin/omz.sh Executable file
View file

@ -0,0 +1,41 @@
#!/bin/zsh
function omz_usage() {
echo "OH MY ZSH! command line tool. Available commands:"
echo " plugin NAME Enable plugin specified by NAME"
echo " theme Choose theme"
echo " upgrade Upgrade OH MY ZSH!"
echo " uninstall Remove OH MY ZSH! :("
echo " help Show this help"
}
COMMAND=$1
case $COMMAND in
plugin )
shift 1
source $ZSH/tools/omz-plugin.sh $@
;;
theme )
zsh $ZSH/tools/theme_chooser.sh
;;
upgrade )
zsh $ZSH/tools/upgrade.sh
;;
uninstall )
zsh $ZSH/tools/uninstall.sh
;;
help )
omz_usage
;;
* )
omz_usage
;;
esac