]> git.rmz.io Git - dotfiles.git/blobdiff - zsh/aliases/pacman.zsh
bin: turn pac(stat) into a function and make it a lot simpler
[dotfiles.git] / zsh / aliases / pacman.zsh
index d2ef8f876c8cf8d6ce919f5cafe549f6aea75864..8cb322c9e0ad649572beacdd6ce78d34f9b82edf 100644 (file)
@@ -38,6 +38,10 @@ paci() {
 # will only work after another pacman completion has been called first
 compdef '_pacman_completions_all_packages' paci=pacman
 
+pacstat() {
+  LC_ALL=C pacman -Sl | sed -n '/\[installed\]/s/^\([^ ]*\).*/\1/p' | uniq -c
+}
+
 pacdisowned() {
   tmp=${TMPDIR-/tmp}/pacman-disowned-$UID-$$
   db=$tmp/db