diff options
| author | Raghuram Subramani <raghus2247@gmail.com> | 2024-01-27 12:45:54 +0530 |
|---|---|---|
| committer | Raghuram Subramani <raghus2247@gmail.com> | 2024-01-27 12:45:54 +0530 |
| commit | 05f9bc5afd5ac5f671f1dcd3d20774b0987545ec (patch) | |
| tree | aa1a9fbe816b5217f6827ae2a41481f762c6c7f4 /.dwm | |
| parent | cc5a352e65e533cc84358a546c9ee6f1d5a47908 (diff) | |
refactor dotfiles, and use nix
Diffstat (limited to '.dwm')
| -rwxr-xr-x | .dwm/bar.sh | 29 | ||||
| -rwxr-xr-x | .dwm/power.sh | 12 |
2 files changed, 0 insertions, 41 deletions
diff --git a/.dwm/bar.sh b/.dwm/bar.sh deleted file mode 100755 index 966afe8..0000000 --- a/.dwm/bar.sh +++ /dev/null @@ -1,29 +0,0 @@ -#!/bin/bash - -battery() { - capacity="$(cat /sys/class/power_supply/BAT1/capacity)" - case "$(cat /sys/class/power_supply/BAT1/status)" in - Charging) printf " $capacity +";; - Discharging) printf " $capacity -";; - Full) printf " $capacity";; - esac -} - -wlan() { - case "$(cat /sys/class/net/wl*/operstate 2>/dev/null)" in - up) echo " $(iwgetid -r)";; - down) printf " Disconnected";; - esac -} - -clock() { - printf " $(date '+%H:%M')" -} - -user() { - printf "$(whoami)" -} - -while(true) do - xsetroot -name "| $(battery) | $(wlan) | $(clock) | $(user) " && sleep 2 -done diff --git a/.dwm/power.sh b/.dwm/power.sh deleted file mode 100755 index e5c5ad2..0000000 --- a/.dwm/power.sh +++ /dev/null @@ -1,12 +0,0 @@ -#!/bin/bash -chosen=$(printf " Power Off\n Restart\n Suspend\n Hibernate\n Log Out\n Lock" | rofi -dmenu -i -p "Choice:") - -case "$chosen" in - " Power Off") poweroff ;; - " Restart") reboot ;; - " Suspend") systemctl suspend-then-hibernate ;; - " Hibernate") systemctl hibernate ;; - " Log Out") killall dwm ;; - " Lock") betterlockscreen -l ;; - *) exit 1 ;; -esac |
