Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Bélanger <snowmaniscool@gmail.com>2012-02-16 00:56:29 -0500
committerDan McGee <dan@archlinux.org>2012-02-16 17:30:24 -0600
commit242006933d31c88b844f8f8d0c2f0806763cc51f (patch)
tree54ccc0e5d20f8cec98ce767e8098f4792647e2a0
parent85712814cdbfa301e5827fafd6bfb8ac0886079c (diff)
pacsysclean: Fix script description and accept -o option without hyphen
Close FS#28434 Signed-off-by: Eric Bélanger <snowmaniscool@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
-rwxr-xr-xcontrib/pacsysclean.in7
1 files changed, 5 insertions, 2 deletions
diff --git a/contrib/pacsysclean.in b/contrib/pacsysclean.in
index c87082e0..a4accd56 100755
--- a/contrib/pacsysclean.in
+++ b/contrib/pacsysclean.in
@@ -1,11 +1,11 @@
#!/bin/bash
-# pacsysclean - Sort installed packages by decreasing installed size. Useful for system clean-up.
+# pacsysclean - Sort installed packages by increasing installed size. Useful for system clean-up.
PACMAN_OPTS=
usage() {
- echo "pacsysclean - Sort installed packages by decreasing installed size."
+ echo "pacsysclean - Sort installed packages by increasing installed size."
echo
echo "Usage: pacsysclean [options]"
echo
@@ -26,6 +26,9 @@ fi
IFS=$'\n'
name="^Name.*: (.*)$"
size="^Installed Size.*: (.*) KiB$"
+
+[[ $PACMAN_OPTS != -* ]] && PACMAN_OPTS="-$PACMAN_OPTS"
+
for line in $(LANG=C pacman -Qi $PACMAN_OPTS); do
if [[ $line =~ $name ]]; then
printf "%s\t" ${BASH_REMATCH[1]}