[shellcheck] SC1004,SC2086 fixes in bash_completion
parent
60ba4bca0c
commit
9963660a11
|
@ -17,11 +17,11 @@ __nvm_commands ()
|
||||||
|
|
||||||
current_word="${COMP_WORDS[COMP_CWORD]}"
|
current_word="${COMP_WORDS[COMP_CWORD]}"
|
||||||
|
|
||||||
COMMANDS='\
|
COMMANDS='
|
||||||
help install uninstall use run exec \
|
help install uninstall use run exec
|
||||||
alias unalias reinstall-packages \
|
alias unalias reinstall-packages
|
||||||
current list ls list-remote ls-remote \
|
current list ls list-remote ls-remote
|
||||||
clear-cache deactivate unload \
|
clear-cache deactivate unload
|
||||||
version which'
|
version which'
|
||||||
|
|
||||||
if [ ${#COMP_WORDS[@]} == 4 ]; then
|
if [ ${#COMP_WORDS[@]} == 4 ]; then
|
||||||
|
@ -56,8 +56,8 @@ __nvm_aliases ()
|
||||||
{
|
{
|
||||||
declare aliases
|
declare aliases
|
||||||
aliases=""
|
aliases=""
|
||||||
if [ -d $NVM_DIR/alias ]; then
|
if [ -d "$NVM_DIR/alias" ]; then
|
||||||
aliases="$(cd $NVM_DIR/alias && command find $PWD -type f | command sed "s:$PWD/::")"
|
aliases="$(cd "$NVM_DIR/alias" && command find "$PWD" -type f | command sed "s:$PWD/::")"
|
||||||
fi
|
fi
|
||||||
echo "${aliases} node stable unstable iojs"
|
echo "${aliases} node stable unstable iojs"
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue