Fix checks for battery plugin
These now check for the presence of the required function instead of checking for the battery file in the enabled directory.
This commit is contained in:
@@ -117,7 +117,7 @@ ${D_BRANCH_COLOR}%b %r ${D_CHANGES_COLOR}%m%u ${D_DEFAULT_COLOR}"
|
||||
|
||||
# checks if the plugin is installed before calling battery_charge
|
||||
safe_battery_charge() {
|
||||
if [ -e "${BASH_IT}/plugins/enabled/battery.plugin.bash" ];
|
||||
if command_exists battery_charge ;
|
||||
then
|
||||
battery_charge
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user