Added dwm helpers for laptop computers

This commit is contained in:
2019-05-04 20:18:08 -07:00
parent b3c4b69d29
commit f2602d913b
2 changed files with 52 additions and 0 deletions

11
dwm_status.laptop Executable file
View File

@@ -0,0 +1,11 @@
#!/bin/bash
# vim: filetype=sh
VOL=$(amixer get Master | tail -1 | sed 's/.*\[\([0-9]*%\)\].*/\1/')
LOCALTIME=$(date +"%Y %h %d %I:%M%p %Z")
IP=$(for i in `ip r`; do echo $i; done | grep -A 1 src | tail -n1)
WEATHER=$(weather fips4105192520 | grep Tempera | awk '{print $2}')
BAT=$(acpi -b | awk '{ print $4 " " $5 }' | tr -d ',')
xsetroot -name " 🔊 $VOL | $IP | 🔋 $BAT | ${WEATHER}°F | $LOCALTIME"