1. Peter Ward
  2. dotfiles/base

Commits

Peter Ward  committed c8921b6

Hide battery errors.

  • Participants
  • Parent commits 2e01026
  • Branches default

Comments (0)

Files changed (1)

File .bash_it/plugins/available/battery.plugin.bash

View file
 battery_percentage(){
   if command_exists acpi;
   then
-    local ACPI_OUTPUT=$(acpi -b)
+    local ACPI_OUTPUT=$(acpi -b 2>/dev/null)
     case $ACPI_OUTPUT in
       *" Unknown"*) 
         local PERC_OUTPUT=$(echo $ACPI_OUTPUT | head -c 22 | tail -c 2)