mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2025-12-26 02:12:33 +01:00
Merge 8583db482d into 41dbf794ba
This commit is contained in:
commit
be5205d7f3
2 changed files with 12 additions and 3 deletions
10
plugins/c/c.plugin.zsh
Normal file
10
plugins/c/c.plugin.zsh
Normal file
|
|
@ -0,0 +1,10 @@
|
||||||
|
function c() {
|
||||||
|
cd ~/Dev/$1;
|
||||||
|
}
|
||||||
|
|
||||||
|
#compdef c
|
||||||
|
function _c () {
|
||||||
|
_files -W ~/Dev -/
|
||||||
|
}
|
||||||
|
|
||||||
|
compdef _c c
|
||||||
|
|
@ -11,11 +11,10 @@ function _cap () {
|
||||||
if [ -f config/deploy.rb ]; then
|
if [ -f config/deploy.rb ]; then
|
||||||
if _cap_does_task_list_need_generating; then
|
if _cap_does_task_list_need_generating; then
|
||||||
echo "\nGenerating .cap_tasks~..." > /dev/stderr
|
echo "\nGenerating .cap_tasks~..." > /dev/stderr
|
||||||
cap show_tasks -q | cut -d " " -f 1 | sed -e '/^ *$/D' -e '1,2D'
|
cap --tasks | grep '#' | cut -d " " -f 2 > .cap_tasks~
|
||||||
> .cap_tasks~
|
|
||||||
fi
|
fi
|
||||||
compadd `cat .cap_tasks~`
|
compadd `cat .cap_tasks~`
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
compctl -K _cap cap
|
compdef _cap cap
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue