wcsfilecmp: punctuation [\]^_` after A-Z.

This tweaks wcsfilecmp such that certain punctuation characters will
come after A-Z.

A big win with `set <TAB>` - the __prefixed fish junk now comes
after the stuff users should care about.
This commit is contained in:
Aaron Gyes 2019-03-16 00:54:44 -07:00
parent 88d20e257b
commit 74a22ff426
2 changed files with 4 additions and 2 deletions

View file

@ -61,8 +61,8 @@ int wcsfilecmp(const wchar_t *a, const wchar_t *b) {
if (retval || *a == 0 || *b == 0) break;
}
wint_t al = towlower(*a);
wint_t bl = towlower(*b);
wint_t al = towupper(*a);
wint_t bl = towupper(*b);
if (al < bl) {
retval = -1;
break;

View file

@ -6,6 +6,8 @@ test/data/ Directory
# __fish_complete_directories test/data/
test/data/abc/ Directory
test/data/abcd/ Directory
test/data/fish-symlink/ Directory
test/data/fish-symlink2/ Directory
test/data/fish/ Directory
test/data/xy/ Directory
test/data/xyz/ Directory