handle powerline not existing

This commit is contained in:
2016-06-10 16:24:39 -07:00
parent 1315de4b37
commit 27f2baa4da
3 changed files with 9 additions and 6 deletions

View File

@@ -421,3 +421,11 @@ function jump_cd {
function source_if_exists {
test -r "$1" && source "$1"
}
function python_module_exists {
python_module_path $@ 1>/dev/null 2>/dev/null
}
function set_default_prompt {
python_module_exists powerline && set_powerline_prompt || set_my_prompt
}