From 2eb4f10b84c3918c178675a5d32cc457209a38f9 Mon Sep 17 00:00:00 2001 From: nerrufam <58603397+nerrufam@users.noreply.github.com> Date: Sun, 16 Feb 2020 02:11:20 +0100 Subject: [PATCH 1/4] Updated moonphase (#484) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Now accepts a date as argument, to know pom of a diff date. Corrected some typos, and a logic error of mine 😄 --- .local/bin/statusbar/moonphase | 25 ++++++++++++------------- 1 file changed, 12 insertions(+), 13 deletions(-) diff --git a/.local/bin/statusbar/moonphase b/.local/bin/statusbar/moonphase index 6ccc81b..d2bbad6 100644 --- a/.local/bin/statusbar/moonphase +++ b/.local/bin/statusbar/moonphase @@ -1,18 +1,17 @@ #!/bin/sh -mnphs=$(pom | grep -io 'new\|waxing cresent\|first quarter\|waxing gibbous\|full\|waning gibbous\|last quarter\|waning cresent' | grep -m1 '.') -prcnt=$(pom | grep -o '..%') - -case $mnphs in - "New") icon="🌑" ;; - "Waxing Cresent") icon="🌒" ;; - "First Quarter") icon="🌓" ;; - "Waxing Gibbous") icon="🌔" ;; - "Full") icon="🌕" ;; - "Waning Gibbous") icon="🌖" ;; - "Last Quarter") icon="🌗" ;; - "Waning Cresent") icon="🌘" ;; - *) echo errorrrr ;; +mnphs=$(pom $1 | grep -o 'New\|Waxing Crescent\|First Quarter\|Waxing Gibbous\|Full\|Waning Gibbous\|Last Quarter\|Waning Crescent' | grep -m1 '.') +prcnt=$(pom $1 | grep -o '[[:digit:]]*%') +case "$mnphs" in + "New") icon="🌑" prcnt="0%" ;; + "Waxing Crescent") icon="🌒" ;; + "First Quarter") icon="🌓" prcnt="50%" ;; + "Waxing Gibbous") icon="🌔" ;; + "Full") icon="🌕" prcnt="100%" ;; + "Waning Gibbous") icon="🌖" ;; + "Last Quarter") icon="🌗" prcnt="50%" ;; + "Waning Crescent") icon="🌘" ;; + *) echo errorrrr ;; esac printf "%s %s\\n" "$icon" "$prcnt" From dab3ae5be0c4a6565394694a6e9cdc61cdeb8d03 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anton=C3=ADn=20Dach?= Date: Tue, 3 Mar 2020 22:50:10 +0100 Subject: [PATCH 2/4] Update lfrc (#495) Prevent globing, filenames with spaces will not open. --- .config/lf/lfrc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.config/lf/lfrc b/.config/lf/lfrc index 18a7e53..27900a1 100644 --- a/.config/lf/lfrc +++ b/.config/lf/lfrc @@ -70,5 +70,5 @@ map reload map shell map x $$f map X !$f -map o &mimeopen $f -map O $mimeopen --ask $f +map o &mimeopen "$f" +map O $mimeopen --ask "$f" From 884b14145a224a2dbc96bcccdd6b47fe00c48d83 Mon Sep 17 00:00:00 2001 From: nerrufam <58603397+nerrufam@users.noreply.github.com> Date: Wed, 4 Mar 2020 15:52:35 +0100 Subject: [PATCH 3/4] to avoid erorr in vifm when pywal is not used (#481) --- .local/bin/setbg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.local/bin/setbg b/.local/bin/setbg index 0927988..87096a6 100755 --- a/.local/bin/setbg +++ b/.local/bin/setbg @@ -8,7 +8,7 @@ [ ! -z "$1" ] && cp "$1" ~/.config/wall.png && notify-send -i "$HOME/.config/wall.png" "Wallpaper changed." # If pywal is installed, use it. -type wal >/dev/null && { wal -c ; +type wal >/dev/null 2>&1 && { wal -c ; wal -s -i ~/.config/wall.png -o ~/.config/wal/postrun; xsetroot -name "fsignal:xrdb"; killall dwmblocks; From ccf8e188c1d7c7b0bf1413c7b856e9dae485ce7c Mon Sep 17 00:00:00 2001 From: Charlie39 Date: Wed, 4 Mar 2020 20:23:18 +0530 Subject: [PATCH 4/4] Added instructive suggestion in the comments (#488) It looks more mass appealing with the details. --- .local/bin/statusbar/battery | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.local/bin/statusbar/battery b/.local/bin/statusbar/battery index d1631db..d9506f0 100755 --- a/.local/bin/statusbar/battery +++ b/.local/bin/statusbar/battery @@ -1,5 +1,5 @@ #!/bin/sh -# Give a battery name (e.g. BAT0) as an argument. +# Give a battery name (Check the battery name from sys/class/power_supply/ e.g. BAT0 or BAT1 and pass it as an argument. case $BLOCK_BUTTON in 3) pgrep -x dunst >/dev/null && notify-send "🔋 Battery module" "🔋: discharging