Battery : Replace cap info with all the info.
This commit is contained in:
parent
3c2b2d9f46
commit
3445c1d000
|
@ -4,9 +4,9 @@ function battery_charge() {
|
||||||
echo '%'
|
echo '%'
|
||||||
}
|
}
|
||||||
|
|
||||||
# Get battery's remaining max capacity in percents.
|
# Get battery's info.
|
||||||
function battery_capacity() {
|
function battery_info() {
|
||||||
local IFS=$'\n'
|
local IFS=$'\n'
|
||||||
local battery=("$(upower --enumerate | grep battery_BAT)")
|
local battery=("$(upower --enumerate | grep battery_BAT)")
|
||||||
upower -i "${battery[0]}" | grep capacity | cut -d\ -f17
|
upower -i "${battery[0]}"
|
||||||
}
|
}
|
||||||
|
|
|
@ -35,7 +35,7 @@ Command|Description
|
||||||
Command|Description
|
Command|Description
|
||||||
---|---
|
---|---
|
||||||
`battery_charge`| Print current battery charge in percents.
|
`battery_charge`| Print current battery charge in percents.
|
||||||
`battery_capacity`| Get battery's remaining max capacity in percents.
|
`battery_info`| Get battery's info.
|
||||||
|
|
||||||
## Bootstrap.
|
## Bootstrap.
|
||||||
|
|
||||||
|
|
Reference in a new issue