added sort to uniquifier; uniq wants sorted input
authorChris Koeritz <fred@gruntose.com>
Sat, 14 Oct 2017 13:48:30 +0000 (09:48 -0400)
committerChris Koeritz <fred@gruntose.com>
Sat, 14 Oct 2017 13:48:30 +0000 (09:48 -0400)
scripts/core/functions.sh

index 6c6832ae70e2d10f4fd7c2d30d346ac48304cc18..c8bcfe34b46715cf0436db59a51c20b6d8758b9e 100644 (file)
@@ -87,7 +87,7 @@ if [ -z "$skip_all" ]; then
     HOLDIFS="$IFS"
     IFS=' '
     # do the uniquification.
-    echo $* | uniq
+    echo $* | sort | uniq
     # return the former eol characters to their place.
     IFS="$HOLDIFS"
   }