From 107a99f2743b8412d667c10998677d9ed6ca8fc5 Mon Sep 17 00:00:00 2001 From: Luke Smith Date: Thu, 25 Jun 2020 09:30:04 -0400 Subject: [PATCH 01/20] quicker, suppress output --- .local/bin/statusbar/help-icon | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.local/bin/statusbar/help-icon b/.local/bin/statusbar/help-icon index 5044324b..8fa4a52c 100755 --- a/.local/bin/statusbar/help-icon +++ b/.local/bin/statusbar/help-icon @@ -3,7 +3,7 @@ # The clickable help menu. Middle click to restart wm. # If dwm is running, use dwm's readme and restart. -pgrep -f "\sdwm$" && +pidof dwm >/dev/null && READMEFILE=/usr/local/share/dwm/larbs.mom restartwm() { pkill -HUP dwm ;} || restartwm() { i3 restart ;} From a0c659d719f11c1606b4e19811a627277524424e Mon Sep 17 00:00:00 2001 From: David Pedersen Date: Sun, 28 Jun 2020 20:59:36 +0200 Subject: [PATCH 02/20] Prevent error when having no battery (#731) * Prevent error when having no battery * Send error to /dev/null instead of separate check --- .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 a6fb62d1..35365347 100755 --- a/.local/bin/statusbar/battery +++ b/.local/bin/statusbar/battery @@ -20,7 +20,7 @@ esac for battery in /sys/class/power_supply/BAT? do # Get its remaining capacity and charge status. - capacity=$(cat "$battery"/capacity) || break + capacity=$(cat "$battery"/capacity 2>/dev/null) || break status=$(sed "s/[Dd]ischarging/🔋/;s/[Nn]ot charging/🛑/;s/[Cc]harging/🔌/;s/[Uu]nknown/♻️/;s/[Ff]ull/⚡/" "$battery"/status) # If it is discharging and 25% or less, we will add a ❗ as a warning. From 2578719227ad51afcc2a0b69e56a0a0c4166e704 Mon Sep 17 00:00:00 2001 From: Dennis Lee Date: Mon, 29 Jun 2020 10:25:29 +0000 Subject: [PATCH 03/20] statusbar/clock: calcurse: use default folder (#734) --- .local/bin/statusbar/clock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.local/bin/statusbar/clock b/.local/bin/statusbar/clock index 1b433920..af501170 100755 --- a/.local/bin/statusbar/clock +++ b/.local/bin/statusbar/clock @@ -20,7 +20,7 @@ esac case $BLOCK_BUTTON in 1) notify-send "This Month" "$(cal --color=always | sed "s/..7m//;s/..27m/<\/span><\/b>/")" && notify-send "Appointments" "$(calcurse -D ~/.config/calcurse -d3)" ;; - 2) setsid -f "$TERMINAL" -e calcurse -D ~/.config/calcurse ;; + 2) setsid -f "$TERMINAL" -e calcurse ;; 3) notify-send "📅 Time/date module" "\- Left click to show upcoming appointments for the next three days via \`calcurse -d3\` and show the month via \`cal\` - Middle click opens calcurse if installed" ;; 6) "$TERMINAL" -e "$EDITOR" "$0" ;; From 49b858c267f2a1528499d9e61794a2f825787f06 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petar=20Tomi=C4=87?= Date: Mon, 29 Jun 2020 16:02:18 +0200 Subject: [PATCH 04/20] fix dmenumount (#735) --- .local/bin/dmenumount | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.local/bin/dmenumount b/.local/bin/dmenumount index 75e11b55..488522a6 100755 --- a/.local/bin/dmenumount +++ b/.local/bin/dmenumount @@ -49,7 +49,7 @@ asktype() { \ } anddrives=$(simple-mtpfs -l 2>/dev/null) -usbdrives="$(lsblk -rpo "name,type,size,mountpoint" | awk '$4==""{printf "%s (%s)\n",$1,$3}')" +usbdrives="$(lsblk -rpo "name,type,size,mountpoint" | grep 'part\|rom' | awk '$4==""{printf "%s (%s)\n",$1,$3}')" if [ -z "$usbdrives" ]; then [ -z "$anddrives" ] && echo "No USB drive or Android device detected" && exit From a78246219a6945b6a67f402c2e137de7f68ddb4a Mon Sep 17 00:00:00 2001 From: Marc <40807627+marcwallach@users.noreply.github.com> Date: Mon, 29 Jun 2020 11:03:55 -0300 Subject: [PATCH 05/20] Add support for boomer file names with spaces (#716) --- .local/bin/opout | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.local/bin/opout b/.local/bin/opout index 23f044e6..7f452df0 100755 --- a/.local/bin/opout +++ b/.local/bin/opout @@ -4,9 +4,9 @@ # usually the pdf of a compiled document. I find this useful especially # running from vim. -basename="$(echo "$1" | sed 's/\.[^\/.]*$//')" +basename="$(echo "${*}" | sed 's/\.[^\/.]*$//')" -case "$1" in +case "${*}" in *.tex|*.m[dse]|*.[rR]md|*.mom|*.[0-9]) setsid -f xdg-open "$basename".pdf >/dev/null 2>&1 ;; *.html) setsid -f "$BROWSER" "$basename".html >/dev/null 2>&1 ;; *.sent) setsid -f sent "$1" >/dev/null 2>&1 ;; From f11008c619e1746d0d3f25c471343c1591200941 Mon Sep 17 00:00:00 2001 From: jamazi <31401744+jamazi@users.noreply.github.com> Date: Thu, 2 Jul 2020 17:59:54 +0300 Subject: [PATCH 07/20] improve speed format (#738) * improve speed format Convert network speed into human-readable format using numfmt, this will handle low and high values properly. * Update nettraf fix jitter --- .local/bin/statusbar/nettraf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.local/bin/statusbar/nettraf b/.local/bin/statusbar/nettraf index ac434165..af61d5a6 100755 --- a/.local/bin/statusbar/nettraf +++ b/.local/bin/statusbar/nettraf @@ -19,10 +19,10 @@ update() { cache=${XDG_CACHE_HOME:-$HOME/.cache}/${1##*/} [ -f "$cache" ] && read -r old < "$cache" || old=0 printf %d\\n "$sum" > "$cache" - printf %d\\n $(( (sum - old) / 1024 )) + printf %d\\n $(( sum - old )) } rx=$(update /sys/class/net/[ew]*/statistics/rx_bytes) tx=$(update /sys/class/net/[ew]*/statistics/tx_bytes) -printf "🔻%dKiB 🔺%dKiB\\n" "$rx" "$tx" +printf "🔻%4sB 🔺%4sB\\n" $(numfmt --to=iec $rx) $(numfmt --to=iec-i $tx) From 93f3711e3958b2ee3bc4ccc2def7fddf0d578584 Mon Sep 17 00:00:00 2001 From: Ddone Date: Thu, 2 Jul 2020 18:01:45 +0300 Subject: [PATCH 08/20] Add cpubars script for dwmblocks (#736) This script shows CPU load --- .local/bin/statusbar/cpubars | 45 ++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100755 .local/bin/statusbar/cpubars diff --git a/.local/bin/statusbar/cpubars b/.local/bin/statusbar/cpubars new file mode 100755 index 00000000..d960727b --- /dev/null +++ b/.local/bin/statusbar/cpubars @@ -0,0 +1,45 @@ +#!/bin/sh + +# Module showing CPU load as a changing bars. +# Just like in polybar. +# Each bar represents amount of load on one core since +# last run. + +# Cache in tmpfs to improve speed and reduce SSD load +cache=/tmp/cpubarscache + +case $BLOCK_BUTTON in + 2) setsid -f "$TERMINAL" -e htop ;; + 3) notify-send "🪨 CPU load module" "Each bar represents +one CPU core";; + 6) "$TERMINAL" -e "$EDITOR" "$0" ;; +esac + +# id total idle +stats=$(awk '/cpu[0-9]+/ {printf "%d %d %d\n", substr($1,4), ($2 + $3 + $4 + $5), $5 }' /proc/stat) +[ ! -f $cache ] && echo "$stats" > "$cache" +old=$(cat "$cache") +echo -n "🪨" +echo "$stats" | while read row; do + id=${row%% *} + rest=${row#* } + total=${rest%% *} + idle=${rest##* } + + case "$(echo "$old" | awk '{if ($1 == id) + printf "%d\n", (1 - (idle - $3) / (total - $2))*100 /12.5}' \ + id=$id total=$total idle=$idle)" in + + "0") echo -n "▁";; + "1") echo -n "▂";; + "2") echo -n "▃";; + "3") echo -n "▄";; + "4") echo -n "▅";; + "5") echo -n "▆";; + "6") echo -n "▇";; + "7") echo -n "█";; + "8") echo -n "█";; + esac +done +echo "" +echo "$stats" > "$cache" From ac7d2ddffc0cd155c971b63ef9c7a9db649baaa5 Mon Sep 17 00:00:00 2001 From: Luke Smith Date: Thu, 2 Jul 2020 15:28:31 -0400 Subject: [PATCH 09/20] price module update fix --- .local/bin/statusbar/price | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.local/bin/statusbar/price b/.local/bin/statusbar/price index 3f87f7a8..45b01adb 100755 --- a/.local/bin/statusbar/price +++ b/.local/bin/statusbar/price @@ -11,18 +11,18 @@ dir="${XDG_DATA_HOME:-$HOME/.local/share}/crypto-prices" pricefile="$dir/$1" chartfile="$dir/$1-chart" -updateprice() { ping -q -c 1 1.1.1.1 >/dev/null 2>&1 && +updateprice() { ping -q -c 1 example.org >/dev/null 2>&1 && curl -s "rate.sx/1$1" > "$pricefile" && curl -s "rate.sx/$1$interval" > "$chartfile" ;} [ -d "$dir" ] || mkdir -p "$dir" [ "$(stat -c %x "$pricefile" 2>/dev/null | cut -d' ' -f1)" != "$(date '+%Y-%m-%d')" ] && - updateprice + updateprice "$1" case $BLOCK_BUTTON in 1) setsid "$TERMINAL" -e less -Sf "$chartfile" ;; - 2) notify-send -u low "$3 Updating..." "Updating $2 price..." && + 2) notify-send -u low "$3 Updating..." "Updating $2 price..." updateprice "$1" && notify-send "$3 Update complete." "$2 price is now \$$(cat "$pricefile")" ;; 3) uptime="$(date -d "$(stat -c %x "$pricefile")" '+%D at %T' | sed "s|$(date '+%D')|Today|")" From 00534b7ccaf410a85a11301c2c0ffdfae5bd8a5e Mon Sep 17 00:00:00 2001 From: Luke Smith Date: Thu, 2 Jul 2020 15:32:36 -0400 Subject: [PATCH 10/20] posix fixes --- .local/bin/statusbar/cpubars | 31 +++++++++++++++---------------- 1 file changed, 15 insertions(+), 16 deletions(-) diff --git a/.local/bin/statusbar/cpubars b/.local/bin/statusbar/cpubars index d960727b..297424e7 100755 --- a/.local/bin/statusbar/cpubars +++ b/.local/bin/statusbar/cpubars @@ -10,7 +10,7 @@ cache=/tmp/cpubarscache case $BLOCK_BUTTON in 2) setsid -f "$TERMINAL" -e htop ;; - 3) notify-send "🪨 CPU load module" "Each bar represents + 3) notify-send "🪨 CPU load module" "Each bar represents one CPU core";; 6) "$TERMINAL" -e "$EDITOR" "$0" ;; esac @@ -19,27 +19,26 @@ esac stats=$(awk '/cpu[0-9]+/ {printf "%d %d %d\n", substr($1,4), ($2 + $3 + $4 + $5), $5 }' /proc/stat) [ ! -f $cache ] && echo "$stats" > "$cache" old=$(cat "$cache") -echo -n "🪨" -echo "$stats" | while read row; do +printf "🪨" +echo "$stats" | while read -r row; do id=${row%% *} rest=${row#* } total=${rest%% *} idle=${rest##* } - case "$(echo "$old" | awk '{if ($1 == id) + case "$(echo "$old" | awk '{if ($1 == id) printf "%d\n", (1 - (idle - $3) / (total - $2))*100 /12.5}' \ - id=$id total=$total idle=$idle)" in + id="$id" total="$total" idle="$idle")" in - "0") echo -n "▁";; - "1") echo -n "▂";; - "2") echo -n "▃";; - "3") echo -n "▄";; - "4") echo -n "▅";; - "5") echo -n "▆";; - "6") echo -n "▇";; - "7") echo -n "█";; - "8") echo -n "█";; + "0") printf "▁";; + "1") printf "▂";; + "2") printf "▃";; + "3") printf "▄";; + "4") printf "▅";; + "5") printf "▆";; + "6") printf "▇";; + "7") printf "█";; + "8") printf "█";; esac -done -echo "" +done; printf "\\n" echo "$stats" > "$cache" From 1ca7338596d10c8ff44b117e91e842dd6275a0ff Mon Sep 17 00:00:00 2001 From: Luke Smith Date: Thu, 2 Jul 2020 15:35:15 -0400 Subject: [PATCH 11/20] ping example.org instead of cloudflare's 1.1.1.1 --- .local/bin/cron/checkup | 2 +- .local/bin/cron/newsup | 2 +- .local/bin/statusbar/crypto | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.local/bin/cron/checkup b/.local/bin/cron/checkup index 34ed61e3..bf7f85d6 100755 --- a/.local/bin/cron/checkup +++ b/.local/bin/cron/checkup @@ -2,7 +2,7 @@ # Syncs repositories and downloads updates, meant to be run as a cronjob. -ping -q -c 1 1.1.1.1 > /dev/null || exit +ping -q -c example.org > /dev/null || exit notify-send "📦 Repository Sync" "Checking for package updates..." diff --git a/.local/bin/cron/newsup b/.local/bin/cron/newsup index 94cfd873..29f2b3c9 100755 --- a/.local/bin/cron/newsup +++ b/.local/bin/cron/newsup @@ -3,7 +3,7 @@ # Set as a cron job to check for new RSS entries for newsboat. # If newsboat is open, sends it an "R" key to refresh. -ping -q -c 1 1.1.1.1 > /dev/null || exit +ping -q -c 1 example.org > /dev/null || exit /usr/bin/notify-send "📰 Updating RSS feeds..." diff --git a/.local/bin/statusbar/crypto b/.local/bin/statusbar/crypto index ef025d49..94ed9496 100755 --- a/.local/bin/statusbar/crypto +++ b/.local/bin/statusbar/crypto @@ -36,7 +36,7 @@ printprices() { # Print/format all prices # If currencies haven't been updated today, try to update them. [ "$(stat -c %x "$HOME/.local/share/crypto-prices" | cut -d' ' -f1)" != "$(date '+%Y-%m-%d')" ] && - { ping -q -c 1 1.1.1.1 >/dev/null 2>&1 && getprices || exit ;} + { ping -q -c 1 example.org >/dev/null 2>&1 && getprices || exit ;} case $BLOCK_BUTTON in 1) uptime="$(date -d "$(stat -c %x "$dir")" '+%D at %T' | sed "s|$(date '+%D')|Today|")" From 595b78aa4fff2d56893a8ce6d2a88dce8c719550 Mon Sep 17 00:00:00 2001 From: Luke Bubar <43391582+lukerb52@users.noreply.github.com> Date: Thu, 2 Jul 2020 18:27:07 -0400 Subject: [PATCH 12/20] Added some more `lf` emojis (#741) * Added more lf emoji tags * On branch export Changes to be committed: modified: .zprofile Changes not staged for commit: modified: .config/aliasrc typechange: .config/dunst/dunstrc modified: .config/lf/lfrc modified: .config/mimeapps.list modified: .config/user-dirs.dirs typechange: .config/zathura/zathurarc modified: .local/share/bg typechange: .xprofile deleted: FUNDING.yml deleted: LICENSE deleted: README.md Untracked files: .ICEauthority .PlayOnLinux/ .Xauthority .abook/ .bash_history .bash_logout .bash_profile .bashrc .cache/ .cddb/ .config/BraveSoftware/ .config/Code - OSS/ .config/Electron/ .config/GIMP/ .config/Microsoft/ .config/Mumble/ .config/MusicBrainz/ .config/OpenSCAD/ .config/QtProject.conf .config/Riot/ .config/Thunar/ .config/VirtualBox/ .config/alsa/ .config/audacious/ .config/autostart/ .config/bashtop/ .config/beets/ .config/calcurse/.calcurse.pid .config/calcurse/apts .config/calcurse/todo .config/cef_user_data/ .config/dconf/ .config/discord/ .config/emaildefaults .config/expressvpn/ .config/ghb/ .config/gnome-boxes/ .config/gtk-2.0/gtkfilechooser.ini .config/htop/ .config/jellyfin-mpv-shim/ .config/k3brc .config/kconf_updaterc .config/kde.org/ .config/kdeglobals .config/libreoffice/ .config/libvirt/ .config/lutris/ .config/lxpanel/ .config/lxqt/ .config/lxsession/ .config/lxterminal/ .config/m64py/ .config/marblerc .config/menus/ .config/midori/ .config/mkeeter/ .config/msmtp/ .config/mupen64plus/ .config/mutt/ .config/ncmpcpp/error.log .config/neofetch/ .config/notmuch-config .config/nvim/autoload/ .config/nvim/plugged/ .config/obs-studio/ .config/octave/ .config/openbox/ .config/pavucontrol.ini .config/pcmanfm/ .config/pulse/ .config/qBittorrent/ .config/qutebrowser/ .config/shortcutrc .config/syncthing/ .config/teams/ .config/tox/ .config/vifm/vifmshortcuts .config/vlc/ .config/wall.png .config/xfce4/ .config/xprofile .config/youtube-viewer/ .config/ysflight/ .config/zoomus.conf .config/zsh/.zcompdump .config/zshnameddirrc .dvdcss/ .fgfs/ .gitconfig .gnome2/ .gnupg/ .hplip/ .java/ .local/bin/lmc .local/bin/mpd-module-update .local/bin/showclip .local/bin/statusbar/corona_america .local/bin/statusbar/corona_world .local/bin/statusbar/help .local/bin/statusbar/statusbarinfo .local/gitter/ .local/lib/ .local/share/Mumble/ .local/share/Steam/ .local/share/TelegramDesktop/ .local/share/TornBanner/ .local/share/Trash/ .local/share/Valve Corporation/ .local/share/applications/METAL GEAR SOLID V THE PHANTOM PAIN.desktop .local/share/applications/Mount & Blade Warband.desktop .local/share/applications/Team Fortress 2.desktop .local/share/applications/mimeinfo.cache .local/share/applications/wine-extension-chm.desktop .local/share/applications/wine-extension-gif.desktop .local/share/applications/wine-extension-hlp.desktop .local/share/applications/wine-extension-htm.desktop .local/share/applications/wine-extension-ini.desktop .local/share/applications/wine-extension-jfif.desktop .local/share/applications/wine-extension-jpe.desktop .local/share/applications/wine-extension-msp.desktop .local/share/applications/wine-extension-pdf.desktop .local/share/applications/wine-extension-png.desktop .local/share/applications/wine-extension-rtf.desktop .local/share/applications/wine-extension-txt.desktop .local/share/applications/wine-extension-url.desktop .local/share/applications/wine-extension-vbs.desktop .local/share/applications/wine-extension-wri.desktop .local/share/applications/wine-extension-xml.desktop .local/share/applications/wine/ .local/share/aspyr-media/ .local/share/calcurse/ .local/share/cargo/ .local/share/crypto-prices/ .local/share/data/ .local/share/desktop-directories/ .local/share/feral-interactive/ .local/share/gsettings-data-convert .local/share/icons/ .local/share/k3b/ .local/share/keyrings/ .local/share/kodi/ .local/share/lf/ .local/share/lutris/ .local/share/mail/ .local/share/marble/ .local/share/mime/ .local/share/moonphase .local/share/multimc/ .local/share/mupen64plus/ .local/share/newsboat/ .local/share/nvim/ .local/share/password-store/ .local/share/qutebrowser/ .local/share/ranger/ .local/share/recently-used.xbel .local/share/rhythmbox/ .local/share/tracker/ .local/share/user-places.xbel .local/share/user-places.xbel.bak .local/share/user-places.xbel.tbcache .local/share/vlc/ .local/share/vulkan/ .local/share/weatherreport .local/share/webkitgtk/ .local/share/wineprefixes/ .local/share/xorg/ .local/share/zathura/ .local/src/ .mbsyncrc .mbwarband/ .mbwarband_backup/ .mbwarband_backup_2/ .minecraft/ .moprc .mozilla/ .octave_hist .octave_packages .openshot_qt/ .pki/ .pulse-cookie .python_history .ssh/ .steam/ .steampath .steampid .tor-browser/ .viminfo .vm/ .vscode-oss/ .waterfox/ .weechat/ .xonotic/ .ysjoycalib .zoom/ Articles/ Documents/ Downloads/ GCC GPUCache/ Games/ METAL GEAR SOLID V THE PHANTOM PAIN.desktop Mount & Blade Warband.desktop Music/ Notes/ Pictures/ Team Fortress 2.desktop The Clone Wars Season 7 Memes-efbk5TMaEy0.jpg The Legend of Pirates Online.desktop The Legend of Pirates Online.lnk Victory and Death-o9_vSjlDl9s.mkv Videos/ bugged_ocean.mkv classes.png larbs.sh octave-workspace octave/ pic-selected-200617-2325-21.png pic-selected-200623-0200-07.png pic-selected-200623-1014-04.png pic-selected-200624-2302-52.png pic-selected-200624-2304-27.png pic-selected-200624-2308-27.png pic-selected-200624-2309-14.png pic-selected-200624-2312-17.png pic-selected-200629-0048-52.png pic-selected-200629-0050-57.png pic-selected-200629-1002-43.png pic-selected-200630-1022-12.png roomate.png steam.desktop ysflightKeyAssign.asn Co-authored-by: Luke Bubar --- .zprofile | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.zprofile b/.zprofile index 4719c28e..8f511ac1 100644 --- a/.zprofile +++ b/.zprofile @@ -73,6 +73,8 @@ ex=🎯:\ *.jpeg=📸:\ *.gif=🖼:\ *.svg=🗺:\ +*.tif=🖼:\ +*.tiff=🖼:\ *.xcf=🖌:\ *.html=🌎:\ *.xml=📰:\ @@ -89,6 +91,7 @@ ex=🎯:\ *.R=📊:\ *.rmd=📊:\ *.Rmd=📊:\ +*.m=📊:\ *.mp3=🎵:\ *.opus=🎵:\ *.ogg=🎵:\ @@ -106,6 +109,9 @@ ex=🎯:\ *.z64=🎮:\ *.v64=🎮:\ *.n64=🎮:\ +*.gba=🎮:\ +*.nes=🎮:\ +*.gdi=🎮:\ *.1=ℹ:\ *.nfo=ℹ:\ *.info=ℹ:\ @@ -116,6 +122,8 @@ ex=🎯:\ *.ged=👪:\ *.part=💔:\ *.torrent=🔽:\ +*.jar=♨:\ +*.java=♨:\ " [ ! -f ${XDG_CONFIG_HOME:-$HOME/.config}/shortcutrc ] && shortcuts >/dev/null 2>&1 & From 9e110a87c7175db47d8b0d89eb8e3b08f94392c4 Mon Sep 17 00:00:00 2001 From: Luke Smith Date: Thu, 2 Jul 2020 21:00:39 -0400 Subject: [PATCH 13/20] fix --- .local/bin/statusbar/nettraf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.local/bin/statusbar/nettraf b/.local/bin/statusbar/nettraf index af61d5a6..71e6fe43 100755 --- a/.local/bin/statusbar/nettraf +++ b/.local/bin/statusbar/nettraf @@ -25,4 +25,4 @@ update() { rx=$(update /sys/class/net/[ew]*/statistics/rx_bytes) tx=$(update /sys/class/net/[ew]*/statistics/tx_bytes) -printf "🔻%4sB 🔺%4sB\\n" $(numfmt --to=iec $rx) $(numfmt --to=iec-i $tx) +printf "🔻%4sB 🔺%4sB\\n" $(numfmt --to=iec $rx) $(numfmt --to=iec $tx) From a19ae72c8278338681ce5f2df33beb6c9cf3ef98 Mon Sep 17 00:00:00 2001 From: Austin Bumbalough Date: Fri, 3 Jul 2020 08:34:43 -0500 Subject: [PATCH 14/20] "$EDITOR $1" caused error in Alacritty terminal. Splitting the qutoes into "$EDITOR" "$1" fixed the issue. Not sure why. (#742) Co-authored-by: Austin Bumbalough --- .local/bin/linkhandler | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.local/bin/linkhandler b/.local/bin/linkhandler index e720641a..7c7e96f7 100755 --- a/.local/bin/linkhandler +++ b/.local/bin/linkhandler @@ -17,6 +17,6 @@ case "$1" in *mp3|*flac|*opus|*mp3?source*) setsid -f tsp curl -LO "$1" >/dev/null 2>&1 ;; *) - if [ -f "$1" ]; then "$TERMINAL" -e "$EDITOR $1" + if [ -f "$1" ]; then "$TERMINAL" -e "$EDITOR" "$1" else setsid -f "$BROWSER" "$1" >/dev/null 2>&1; fi ;; esac From 4dd4959ebd8f494eb0510cafc4df73c56c98a5fc Mon Sep 17 00:00:00 2001 From: Luke Smith Date: Fri, 3 Jul 2020 10:06:49 -0400 Subject: [PATCH 15/20] fix #743 --- .config/directories | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.config/directories b/.config/directories index 250a3b79..29e228f0 100644 --- a/.config/directories +++ b/.config/directories @@ -1,11 +1,11 @@ # You can add comments to these files with # -d ~/Documents -D ~/Downloads -h ${XDG_CONFIG_HOME:-~/} -m ~/Music +d ~/Documents +D ~/Downloads +h ${HOME:-~/} +m ~/Music pp ~/Pictures vv ~/Videos cf ${XDG_CONFIG_HOME:-$HOME/.config} -cac ${XDG_CACHE_HOME:-$HOME/.cache} +cac ${XDG_CACHE_HOME:-$HOME/.cache} mn /mnt sc ~/.local/bin From 9fe33edc77ec8c0e688cb5ef8629a4d3b7e3bbac Mon Sep 17 00:00:00 2001 From: Luke Smith Date: Fri, 3 Jul 2020 10:08:40 -0400 Subject: [PATCH 16/20] more image icons --- .zprofile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.zprofile b/.zprofile index 8f511ac1..53161ed0 100644 --- a/.zprofile +++ b/.zprofile @@ -68,8 +68,10 @@ ex=🎯:\ *.me=✍:\ *.ms=✍:\ *.png=🖼:\ +*.webp=🖼:\ *.ico=🖼:\ *.jpg=📸:\ +*.jpe=📸:\ *.jpeg=📸:\ *.gif=🖼:\ *.svg=🗺:\ From f06ba0df0916265f210a803091f56caf593ae13b Mon Sep 17 00:00:00 2001 From: Ashish Panigrahi Date: Fri, 3 Jul 2020 20:12:26 +0530 Subject: [PATCH 17/20] Corrected spelling (#744) --- .config/nvim/init.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.config/nvim/init.vim b/.config/nvim/init.vim index 48635a4a..b3f40c99 100644 --- a/.config/nvim/init.vim +++ b/.config/nvim/init.vim @@ -103,7 +103,7 @@ set clipboard+=unnamedplus " Save file as sudo on files that require root permission cnoremap w!! execute 'silent! write !sudo tee % >/dev/null' edit! -" Enable Goyo by default for mutt writting +" Enable Goyo by default for mutt writing autocmd BufRead,BufNewFile /tmp/neomutt* let g:goyo_width=80 autocmd BufRead,BufNewFile /tmp/neomutt* :Goyo | set bg=light autocmd BufRead,BufNewFile /tmp/neomutt* map ZZ :Goyo\|x! From 8cba946027f53db3c60a66a0822eeae173c5f743 Mon Sep 17 00:00:00 2001 From: Dennis Lee Date: Sun, 5 Jul 2020 00:07:11 +0000 Subject: [PATCH 18/20] `cff` = fontconfig/fonts.conf (#745) --- .config/files | 1 + 1 file changed, 1 insertion(+) diff --git a/.config/files b/.config/files index 235762fe..ac69a3ba 100644 --- a/.config/files +++ b/.config/files @@ -14,3 +14,4 @@ cfmc ${XDG_CONFIG_HOME:-$HOME/.config}/ncmpcpp/config cfk ${XDG_CONFIG_HOME:-$HOME/.config}/sxhkd/sxhkdrc cfi ${XDG_CONFIG_HOME:-$HOME/.config}/i3/config cfb ${XDG_CONFIG_HOME:-$HOME/.config}/i3blocks/config +cff ${XDG_CONFIG_HOME:-$HOME/.config}/fontconfig/fonts.conf From 53cdc0eb9579770b326fbf61876051cb84185c2d Mon Sep 17 00:00:00 2001 From: anntnzrb <51257127+anntnzrb@users.noreply.github.com> Date: Sun, 5 Jul 2020 15:17:49 -0500 Subject: [PATCH 19/20] Prevent user-defined aliases/commands checking (#748) Adding `[ -x ]` also checks if the command is an executable; if this check is skipped, then user-defined aliases will interfere and validate the condition (unintended). --- .local/bin/compiler | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.local/bin/compiler b/.local/bin/compiler index 213013ed..ac3b8451 100755 --- a/.local/bin/compiler +++ b/.local/bin/compiler @@ -32,9 +32,9 @@ case "$ext" in go) go run "$file" ;; h) sudo make install ;; m) octave "$file" ;; - md) if command -v lowdown >/dev/null; then + md) if [ -x "$(command -v lowdown)" ] >/dev/null; then lowdown -d nointem -e super "$file" -Tms | groff -mpdfmark -ms -kept > "$base".pdf - elif command -v groffdown >/dev/null; then + elif [ -x "$(command -v groffdown)" ] >/dev/null; then groffdown -i "$file" | groff > "$base.pdf" else pandoc "$file" --pdf-engine=xelatex -o "$base".pdf From ae9c12a861d07b792ebe24b85bda1567cc5c37ab Mon Sep 17 00:00:00 2001 From: anntnzrb <51257127+anntnzrb@users.noreply.github.com> Date: Tue, 7 Jul 2020 10:30:26 -0500 Subject: [PATCH 20/20] Remove uneeded std suppression (#749) There's no stdout/stderr on this condition. --- .local/bin/compiler | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.local/bin/compiler b/.local/bin/compiler index ac3b8451..1892d5fb 100755 --- a/.local/bin/compiler +++ b/.local/bin/compiler @@ -32,9 +32,9 @@ case "$ext" in go) go run "$file" ;; h) sudo make install ;; m) octave "$file" ;; - md) if [ -x "$(command -v lowdown)" ] >/dev/null; then + md) if [ -x "$(command -v lowdown)" ]; then lowdown -d nointem -e super "$file" -Tms | groff -mpdfmark -ms -kept > "$base".pdf - elif [ -x "$(command -v groffdown)" ] >/dev/null; then + elif [ -x "$(command -v groffdown)" ]; then groffdown -i "$file" | groff > "$base.pdf" else pandoc "$file" --pdf-engine=xelatex -o "$base".pdf