diff options
| author | Luke Smith <luke@lukesmith.xyz> | 2021-09-23 12:43:16 -0400 |
|---|---|---|
| committer | Luke Smith <luke@lukesmith.xyz> | 2021-09-23 12:43:16 -0400 |
| commit | 5caaa489ac45e23d1c0160ab6668d12585f6bffe (patch) | |
| tree | 261b748295847e22c99dd08d3d9833506bf2ee8f | |
| parent | f42cb321f09e44c00213e186f0208abf51088d33 (diff) | |
| parent | dd8da1765a78117219e8b81d0945baa1e66c3a67 (diff) | |
| download | eibhear-5caaa489ac45e23d1c0160ab6668d12585f6bffe.tar.gz eibhear-5caaa489ac45e23d1c0160ab6668d12585f6bffe.tar.zst eibhear-5caaa489ac45e23d1c0160ab6668d12585f6bffe.zip | |
Merge branch 'master' of github.com:LukeSmithxyz/voidrice
| -rwxr-xr-x | .local/bin/dmenuumount | 2 | ||||
| -rwxr-xr-x | .local/bin/statusbar/sb-internet | 3 | ||||
| -rwxr-xr-x | .local/bin/torwrap | 2 |
3 files changed, 4 insertions, 3 deletions
diff --git a/.local/bin/dmenuumount b/.local/bin/dmenuumount index 52dd7ff..f7d0747 100755 --- a/.local/bin/dmenuumount +++ b/.local/bin/dmenuumount @@ -26,7 +26,7 @@ asktype() { \ esac } -drives=$(lsblk -nrpo "name,type,size,mountpoint" | awk '$4!~/\/boot|\/efi|\/home$|SWAP/&&length($4)>1{printf "%s (%s)\n",$4,$3}') +drives=$(lsblk -nrpo "name,type,size,mountpoint,label" | sed 's/ /:/g' | awk -F':' '$4!~/\/boot|\/efi|\/home$|SWAP/&&length($4)>1{printf "%s (%s) %s\n",$4,$3,$5}') if ! grep simple-mtpfs /etc/mtab; then [ -z "$drives" ] && echo "No drives to unmount." && exit diff --git a/.local/bin/statusbar/sb-internet b/.local/bin/statusbar/sb-internet index ee1a160..d3948d7 100755 --- a/.local/bin/statusbar/sb-internet +++ b/.local/bin/statusbar/sb-internet @@ -7,6 +7,7 @@ case $BLOCK_BUTTON in 1) "$TERMINAL" -e nmtui; pkill -RTMIN+4 dwmblocks ;; 3) notify-send "🌐 Internet module" "\- Click to connect +❌: wifi disabled 📡: no wifi connection 📶: wifi connection with quality ❎: no ethernet @@ -17,7 +18,7 @@ case $BLOCK_BUTTON in esac case "$(cat /sys/class/net/w*/operstate 2>/dev/null)" in - down) wifiicon="📡 " ;; + down) [ "$(cat /sys/class/net/w*/flags)" = "0x1002" ] && wifiicon="❌ " || wifiicon="📡 " ;; up) wifiicon="$(awk '/^\s*w/ { print "📶", int($3 * 100 / 70) "% " }' /proc/net/wireless)" ;; esac diff --git a/.local/bin/torwrap b/.local/bin/torwrap index 4f94053..8b20ad4 100755 --- a/.local/bin/torwrap +++ b/.local/bin/torwrap @@ -1,6 +1,6 @@ #!/bin/sh -ifinstalled tremc-git transmission-cli || exit +ifinstalled tremc transmission-cli || exit ! pidof transmission-daemon >/dev/null && transmission-daemon && notify-send "Starting torrent daemon..." |
