mirror of
https://github.com/deadc0de6/dotdrop.git
synced 2026-02-04 19:09:44 +00:00
adding "remove" option for #47 and fix a few issues/bugs
This commit is contained in:
@@ -5,7 +5,7 @@ _dotdropsh()
|
||||
cur="${COMP_WORDS[COMP_CWORD]}"
|
||||
|
||||
if [ $COMP_CWORD -eq 1 ]; then
|
||||
COMPREPLY=( $( compgen -W '-h --help -v --version install import compare update listfiles detail list' -- $cur) )
|
||||
COMPREPLY=( $( compgen -W '-h --help -v --version install import compare update remove listfiles detail list' -- $cur) )
|
||||
else
|
||||
case ${COMP_WORDS[1]} in
|
||||
install)
|
||||
@@ -19,6 +19,9 @@ _dotdropsh()
|
||||
;;
|
||||
update)
|
||||
_dotdropsh_update
|
||||
;;
|
||||
remove)
|
||||
_dotdropsh_remove
|
||||
;;
|
||||
listfiles)
|
||||
_dotdropsh_listfiles
|
||||
@@ -40,7 +43,7 @@ _dotdropsh_install()
|
||||
cur="${COMP_WORDS[COMP_CWORD]}"
|
||||
|
||||
if [ $COMP_CWORD -ge 2 ]; then
|
||||
COMPREPLY=( $( compgen -fW '-V --verbose -b --no-banner -t --temp -f --force -n --nodiff -d --dry -D --showdiff -a --force-action -c= --cfg= -p= --profile= ' -- $cur) )
|
||||
COMPREPLY=( $( compgen -fW '-V --verbose -b --no-banner -t --temp -f --force -n --nodiff -d --dry -D --showdiff -a --force-actions -c= --cfg= -p= --profile= ' -- $cur) )
|
||||
fi
|
||||
}
|
||||
|
||||
@@ -74,6 +77,16 @@ _dotdropsh_update()
|
||||
fi
|
||||
}
|
||||
|
||||
_dotdropsh_remove()
|
||||
{
|
||||
local cur
|
||||
cur="${COMP_WORDS[COMP_CWORD]}"
|
||||
|
||||
if [ $COMP_CWORD -ge 2 ]; then
|
||||
COMPREPLY=( $( compgen -fW '-V --verbose -b --no-banner -f --force -d --dry -k --key -c= --cfg= -p= --profile= ' -- $cur) )
|
||||
fi
|
||||
}
|
||||
|
||||
_dotdropsh_listfiles()
|
||||
{
|
||||
local cur
|
||||
|
||||
Reference in New Issue
Block a user