From 1b10cba5abb08662a70fae8a5225a29606b20f7a Mon Sep 17 00:00:00 2001 From: eoli3n Date: Thu, 13 May 2021 22:17:11 +0200 Subject: [PATCH] updated waybar pkg module voidlinux --- TODO | 8 +++++--- roles/waybar/files/waybar/modules/pkg.sh | 3 ++- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/TODO b/TODO index a74f522..790cae8 100644 --- a/TODO +++ b/TODO @@ -13,10 +13,12 @@ * firefox menu size when scaling : https://bugzilla.mozilla.org/show_bug.cgi?id=1638168 # IMPROVMENTS -- dynamic waybar colors -- wrapper script to assign new windows to current workspace to avoid wrong workspace when jumping quickly between workspaces - - wrap all .desktop with wofi +- wrap all .desktop with wofi #TEST * wf-recorder - launch kitty in xwayland mode to be able to share window + +# Voidlinux +- [x] waybar upgrade module with xbps-flatpak +- [ ] list xbps updates without need to xbps-install -S as root diff --git a/roles/waybar/files/waybar/modules/pkg.sh b/roles/waybar/files/waybar/modules/pkg.sh index 58adb0b..e9ee74c 100755 --- a/roles/waybar/files/waybar/modules/pkg.sh +++ b/roles/waybar/files/waybar/modules/pkg.sh @@ -18,13 +18,14 @@ pacman_check() { xbps_check(){ pkg=$(xbps-install -nu 2>/dev/null) pkg_count=$(wc -l <<< "$pkg") + flatpak_count=$(flatpak update | grep -E '^ *[0-9]+\.' | awk '{print $2}' | wc -l) if [[ $pkg_count -eq "0" ]] || [[ ! $pkg =~ [0-9]+ ]] then exit 0 fi - text=" $pkg_count" + text="$pkg_count $flatpak_count" tooltip=$(awk -v ORS=' ' '$0=$1' <<< "$pkg") }