aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/justfile
diff options
context:
space:
mode:
Diffstat (limited to 'justfile')
-rw-r--r--justfile20
1 files changed, 20 insertions, 0 deletions
diff --git a/justfile b/justfile
index fe1cc65..fe58d8d 100644
--- a/justfile
+++ b/justfile
@@ -49,3 +49,23 @@ status:
echo ""
echo "=== Dotfile drift ==="
chezmoi status || true
+
+# Show install coverage for each group
+groups:
+ #!/bin/sh
+ for file in meta/*.txt; do
+ group=$(basename "$file" .txt)
+ pkgs=$(grep -v '^\s*#' "$file" | grep -v '^\s*$')
+ total=$(echo "$pkgs" | wc -l)
+ installed=0
+ for pkg in $pkgs; do
+ pacman -Qi "$pkg" >/dev/null 2>&1 && installed=$((installed + 1))
+ done
+ if [ "$installed" -eq "$total" ]; then
+ printf ' \033[32m✓\033[0m %-10s %d/%d\n' "$group" "$installed" "$total"
+ elif [ "$installed" -eq 0 ]; then
+ printf ' \033[31m✗\033[0m %-10s %d/%d\n' "$group" "$installed" "$total"
+ else
+ printf ' \033[33m~\033[0m %-10s %d/%d\n' "$group" "$installed" "$total"
+ fi
+ done