dotfiles

My dotfiles used for LARBS
Log | Files | Refs | README | LICENSE

commit a2e0d2441b56886049892481178a119948fb7866
parent 6c7358074dd25590b4d7c20506b20d80499dd66b
Author: Luke Smith <luke@lukesmith.xyz>
Date:   Fri, 13 Mar 2020 12:33:30 -0400

Merge branch 'master' of github.com:LukeSmithxyz/voidrice

Diffstat:
M.config/lf/lfrc | 4++--
M.local/bin/statusbar/battery | 2+-
M.local/bin/statusbar/moonphase | 25++++++++++++-------------
3 files changed, 15 insertions(+), 16 deletions(-)

diff --git a/.config/lf/lfrc b/.config/lf/lfrc @@ -70,5 +70,5 @@ map <c-r> reload map <enter> 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" diff --git 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 diff --git 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"