prevent battery_charge call from erroring in themes when battery plugin not enabled

pull/367/head
Ben Brunton 2014-11-12 17:27:38 +00:00
parent e7f1bf8645
commit d7912f8f1b
1 changed files with 9 additions and 0 deletions

View File

@ -216,3 +216,12 @@ function scm_char {
function prompt_char { function prompt_char {
scm_char scm_char
} }
if [ ! -e $BASH_IT/plugins/enabled/battery.plugin.bash ]; then
# if user has installed battery plugin, skip this...
function battery_charge (){
# no op
echo -n
}
fi