summaryrefslogtreecommitdiffstats
path: root/.local/bin/statusbar/torrent
diff options
context:
space:
mode:
authorLuke Smith <luke@lukesmith.xyz>2020-09-25 11:41:55 -0400
committerLuke Smith <luke@lukesmith.xyz>2020-09-25 11:41:55 -0400
commit39320cf1eac171ff5ecc847c8e9d36ff92329735 (patch)
treefc4a0ae6ea8658c36adc040e40ec6dbbc46f828e /.local/bin/statusbar/torrent
parentd92bd73428f7c13ec3c3860ab8ee518c336ec458 (diff)
downloadeibhear-39320cf1eac171ff5ecc847c8e9d36ff92329735.tar.gz
eibhear-39320cf1eac171ff5ecc847c8e9d36ff92329735.tar.zst
eibhear-39320cf1eac171ff5ecc847c8e9d36ff92329735.zip
cleanup
Diffstat (limited to '.local/bin/statusbar/torrent')
-rwxr-xr-x.local/bin/statusbar/torrent22
1 files changed, 8 insertions, 14 deletions
diff --git a/.local/bin/statusbar/torrent b/.local/bin/statusbar/torrent
index 9e1da3a..d2e0885 100755
--- a/.local/bin/statusbar/torrent
+++ b/.local/bin/statusbar/torrent
@@ -1,20 +1,14 @@
#!/bin/sh
transmission-remote -l | grep % |
- sed " # This first sed command is to ensure a desirable order with sort
- s/.*Stopped.*/A/g;
- s/.*Seeding.*/Z/g;
- s/.*100%.*/N/g;
- s/.*Idle.*/B/g;
- s/.*Uploading.*/L/g;
- s/.*%.*/M/g" |
- sort -h | uniq -c | sed " # Now we replace the standin letters with icons.
- s/A/🛑/g;
- s/B/🕰/g;
- s/L/🔼/g;
- s/M/🔽/g;
- s/N/✅/g;
- s/Z/🌱/g" | awk '{print $2 $1}' | paste -sd ' '
+ sed " # The letters are for sorting and will not appear.
+ s/.*Stopped.*/A 🛑/;
+ s/.*Seeding.*/Z 🌱/;
+ s/.*100%.*/N ✅/;
+ s/.*Idle.*/B 🕰️/;
+ s/.*Uploading.*/L ⬆️/;
+ s/.*%.*/M ⬇️/" |
+ sort -h | uniq -c | awk '{print $3 $1}' | paste -sd ' '
case $BLOCK_BUTTON in
1) setsid -f "$TERMINAL" -e tremc ;;