1 # ------------------------------------------------------------------------------
2 # FILE: n98-magerun.plugin.zsh
3 # DESCRIPTION: oh-my-zsh n98-magerun plugin file. Adapted from composer plugin
4 # AUTHOR: Andrew Dwyer (andrewrdwyer at gmail dot com)
5 # AUTHOR: Jisse Reitsma (jisse at yireo dot com)
7 # ------------------------------------------------------------------------------
9 # n98-magerun basic command completion
10 _n98_magerun_get_command_list () {
11 $_comp_command1 --no-ansi | sed "1,/Available commands/d" | awk '/^ +[a-z\-:]+/ { print $1 }'
16 _arguments '1: :->command' '*:optional arg:_files'
20 compadd $(_n98_magerun_get_command_list)
26 compdef _n98_magerun n98-magerun.phar
27 compdef _n98_magerun n98-magerun
28 compdef _n98_magerun n98-magerun2.phar
29 compdef _n98_magerun n98-magerun2
32 alias n98='n98-magerun.phar'
33 alias mage='n98-magerun.phar'
34 alias magerun='n98-magerun.phar'
36 alias n98-2='n98-magerun2.phar'
37 alias mage2='n98-magerun2.phar'
38 alias magerun2='n98-magerun2.phar'
40 # Install n98-magerun into the current directory
41 alias mage-get='wget https://files.magerun.net/n98-magerun.phar'
42 alias mage2-get='wget https://files.magerun.net/n98-magerun2.phar'