fix(common): sort -R is random, -r is reverse. Kids, use long options...

Randomly failing builds for fun and profit!
This commit is contained in:
Michael Marineau 2013-08-07 12:38:58 -04:00
parent 5ac0bcdd27
commit a0f383e3fe

View File

@ -165,7 +165,7 @@ cmp_ver() {
local rev a="${2%%+*}" b="${3%%+*}" local rev a="${2%%+*}" b="${3%%+*}"
case "$1" in case "$1" in
le) rev="" ;; le) rev="" ;;
ge) rev="-R" ;; ge) rev="--reverse" ;;
*) die "Invalid operator $1" ;; *) die "Invalid operator $1" ;;
esac esac
printf '%s\n%s\n' "$a" "$b" | sort --version-sort --check=quiet $rev printf '%s\n%s\n' "$a" "$b" | sort --version-sort --check=quiet $rev