Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

fix rpg-list not showing matches or showing '-' as version with -a

  • Loading branch information...
commit 4ad59690bed2fedc98c9ac514380605b3b0856af 1 parent 069834c
@rtomayko authored
Showing with 7 additions and 8 deletions.
  1. +7 −8 rpg-list.sh
View
15 rpg-list.sh
@@ -26,11 +26,13 @@ Options
sync=false
parsey=false
long=false
+all=false
joiner=
while getopts alpus opt
do
case $opt in
- a) joiner="-a2";;
+ a) all=true
+ joiner="-a2";;
l) long=true;;
u) sync=true;;
p) long=true;
@@ -166,13 +168,10 @@ grep -v '. - - .' |
# formatting.
if ! $long
then
- awk '{
- if ( $1 != "-" ) {
- print $1, $2;
- } else if ($4 != "-") {
- print $4, $3;
- }
- }'
+ if $all
+ then awk '$4 != "-" { print $4, $3; }'
+ else awk '$2 != "-" { print $1, $2; }'
+ fi
else
while read package curvers recvers pdup
do
Please sign in to comment.
Something went wrong with that request. Please try again.