Add GLEP 53 keywords sorting patch from prefix
authorfuzzyray <fuzzyray@gentoo.org>
Fri, 1 May 2009 17:39:18 +0000 (17:39 -0000)
committerfuzzyray <fuzzyray@gentoo.org>
Fri, 1 May 2009 17:39:18 +0000 (17:39 -0000)
svn path=/; revision=569

trunk/src/ekeyword/ekeyword

index 2e49ac0bbfe1954a2a7728c0747e432d50667992..002e44be3b1884129f049c32b860a39f40b4b8c0 100755 (executable)
@@ -99,6 +99,10 @@ for my $f (@ARGV) {
                                (my $sb = $b) =~ s/^\W//;
                                return -1 if $sa eq '*';
                                return +1 if $sb eq '*';
+                               $sa .= "-";
+                               $sb .= "-";
+                               $sa =~ s/([a-z0-9]+)-([a-z0-9]*)/$2-$1/g;
+                               $sb =~ s/([a-z0-9]+)-([a-z0-9]*)/$2-$1/g;
                                $sa cmp $sb;
                        } split " ", $quoted;