Prevent unbound variable errors

This commit is contained in:
Jeremy Mathevet
2017-03-21 12:04:18 +00:00
parent 472bf9d97b
commit 588213980d

View File

@@ -2,6 +2,7 @@
THEME_CHECK_SUDO=${THEME_CHECK_SUDO:=true}
function set_color {
set +u
if [[ "${1}" != "-" ]]; then
fg="38;5;${1}"
fi
@@ -13,6 +14,7 @@ function set_color {
}
function __powerline_user_info_prompt {
set +u
local user_info=""
local color=${USER_INFO_THEME_PROMPT_COLOR}
@@ -51,6 +53,7 @@ function __powerline_ruby_prompt {
}
function __powerline_python_venv_prompt {
set +u
local python_venv=""
if [[ -n "${CONDA_DEFAULT_ENV}" ]]; then