zshrc: Add power_now function
This commit is contained in:
parent
3ee2074bd8
commit
7dcb416f6d
1 changed files with 7 additions and 0 deletions
7
zshrc
7
zshrc
|
@ -395,6 +395,13 @@ fi
|
|||
ixio() { curl -F 'f:1=<-' ix.io }
|
||||
0x0st() { curl -F'file=@-' https://0x0.st }
|
||||
|
||||
if [ -f /sys/class/power_supply/BAT0/power_now ]; then
|
||||
power_now() {
|
||||
awk '{ print $1*10^-6 " W" }' \
|
||||
/sys/class/power_supply/BAT0/power_now
|
||||
}
|
||||
fi
|
||||
|
||||
cross() {
|
||||
if [ $# = 0 ]; then
|
||||
echo 'Usage: cross platform [architecture1] [architecture2]' \
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue