diff --git a/themes/base.theme.bash b/themes/base.theme.bash index e4879f3c..2761b632 100644 --- a/themes/base.theme.bash +++ b/themes/base.theme.bash @@ -139,9 +139,9 @@ function scm_prompt_info_common { fi # TODO: consider adding minimal status information for hg and svn - [[ ${SCM} == ${SCM_P4} ]] && p4_prompt_info && return - [[ ${SCM} == ${SCM_HG} ]] && hg_prompt_info && return - [[ ${SCM} == ${SCM_SVN} ]] && svn_prompt_info && return + { [[ ${SCM} == ${SCM_P4} ]] && p4_prompt_info && return; } || true + { [[ ${SCM} == ${SCM_HG} ]] && hg_prompt_info && return; } || true + { [[ ${SCM} == ${SCM_SVN} ]] && svn_prompt_info && return; } || true } function git_prompt_minimal_info { diff --git a/themes/githelpers.theme.bash b/themes/githelpers.theme.bash index 1f43382d..24c4b1f4 100644 --- a/themes/githelpers.theme.bash +++ b/themes/githelpers.theme.bash @@ -72,7 +72,7 @@ function _git-hide-status { function _git-status { local git_status_flags= - [[ "${SCM_GIT_IGNORE_UNTRACKED}" = "true" ]] && git_status_flags='-uno' + [[ "${SCM_GIT_IGNORE_UNTRACKED}" = "true" ]] && git_status_flags='-uno' || true git status --porcelain ${git_status_flags} 2> /dev/null } @@ -101,8 +101,9 @@ function _git-status-counts { } function _git-remote-info { - [[ "$(_git-upstream)" == "" ]] && return + [[ "$(_git-upstream)" == "" ]] && return || true + [[ "$(_git-branch)" == "$(_git-upstream-branch)" ]] && local same_branch_name=true || true local same_branch_name= [[ "$(_git-branch)" == "$(_git-upstream-branch)" ]] && same_branch_name=true if ([[ "${SCM_GIT_SHOW_REMOTE_INFO}" = "auto" ]] && [[ "$(_git-num-remotes)" -ge 2 ]]) ||