Fix some Bash issues
parent
44455c4a00
commit
c86038d61d
|
|
@ -1701,7 +1701,7 @@ _docker_service_tasks() {
|
|||
}
|
||||
|
||||
_docker_service_update() {
|
||||
local $subcommand="${words[$subcommand_pos]}"
|
||||
local subcommand="${words[$subcommand_pos]}"
|
||||
|
||||
local options_with_args="
|
||||
--constraint
|
||||
|
|
|
|||
|
|
@ -111,7 +111,7 @@ __vboxmanage_default() {
|
|||
|
||||
for WORD in $opts; do
|
||||
MATCH=0
|
||||
for OPT in ${COMP_WORDS[@]}; do
|
||||
for OPT in "${COMP_WORDS[@]}"; do
|
||||
# opts=$(echo ${opts} | grep -v $OPT);
|
||||
if [ "$OPT" == "$WORD" ]; then
|
||||
MATCH=1
|
||||
|
|
|
|||
|
|
@ -202,7 +202,7 @@ function git_prompt_vars {
|
|||
SCM_STATE=${GIT_THEME_PROMPT_CLEAN:-$SCM_THEME_PROMPT_CLEAN}
|
||||
if [[ "$(git config --get bash-it.hide-status)" != "1" ]]; then
|
||||
[[ "${SCM_GIT_IGNORE_UNTRACKED}" = "true" ]] && local git_status_flags='-uno'
|
||||
local status_lines=$((git status --porcelain ${git_status_flags} -b 2> /dev/null ||
|
||||
local status_lines=$($(git status --porcelain ${git_status_flags} -b 2> /dev/null ||
|
||||
git status --porcelain ${git_status_flags} 2> /dev/null) | git_status_summary)
|
||||
local status=$(awk 'NR==1' <<< "$status_lines")
|
||||
local counts=$(awk 'NR==2' <<< "$status_lines")
|
||||
|
|
@ -376,7 +376,7 @@ function chruby_version_prompt {
|
|||
|
||||
ruby_version=$(ruby --version | awk '{print $1, $2;}') || return
|
||||
|
||||
if [[ ! $(chruby | grep '*') ]]; then
|
||||
if [[ ! $(chruby | grep '\*') ]]; then
|
||||
ruby_version="${ruby_version} (system)"
|
||||
fi
|
||||
echo -e "${CHRUBY_THEME_PROMPT_PREFIX}${ruby_version}${CHRUBY_THEME_PROMPT_SUFFIX}"
|
||||
|
|
|
|||
Loading…
Reference in New Issue