stash/pkg/utils
SmallCoccinelle 41a1fb8aec
Add collation to directory listings (#1823)
* Add collation to directory listings. Closes #1806

Introduce a new `locale` arg to the `Query.directory` field. Set "en"
as the default for the field for backward compatibility. Use the given
locale, sending it through a language matcher, and use `x/text` as the
collation engine for the matched language.

Augment the file `ListDirs` call to optionally take a Collator. If the
Collator is given, sort file listings according to the collators rules.

While here, document the GraphQL schema a bit more.

Add matchers by looking at the current front-end locales, and make sure
each of these occur in the matcher list.

* Language matcher touchups

* Avoid having `en-US` twice.
* Introduce `en-AU`.

* Pass IgnoreCase and Numeric collation

Allow the collator to be configured with options. Pass the options
IgnoreCase and Numeric to the collator.
2021-10-14 15:16:45 +11:00
..
boolean.go Lint checks phase 2 (#1747) 2021-09-23 17:15:50 +10:00
byterange.go Remove unused (#1709) 2021-09-09 14:10:08 +10:00
context.go Plugin hooks (#1452) 2021-06-11 17:24:58 +10:00
crypto.go Errcheck phase 1 (#1715) 2021-09-21 09:34:25 +10:00
date.go Fix json time when unmarshalling 2019-03-09 10:14:55 -08:00
file.go Add collation to directory listings (#1823) 2021-10-14 15:16:45 +11:00
file_test.go refactor: move from io/ioutil to io and os package (#1772) 2021-09-27 10:55:23 +10:00
float.go Configuration 2019-04-11 10:55:58 -07:00
image.go refactor: move from io/ioutil to io and os package (#1772) 2021-09-27 10:55:23 +10:00
int_collections.go Data layer restructuring (#997) 2021-01-18 12:23:20 +11:00
oshash.go Improve oshash code (#1829) 2021-10-12 11:59:51 +11:00
oshash_internal_test.go Improve oshash code (#1829) 2021-10-12 11:59:51 +11:00
phash.go Add various filter criteria (#1505) 2021-06-23 09:10:20 +10:00
resources.go Change thumbnail default size and resize algorithm (#336) 2020-01-31 17:19:15 -05:00
string_collections.go Discard null values from scraper results (#1374) 2021-05-16 16:40:54 +10:00
strings.go Handle case sensitive file moves (#1427) 2021-06-11 15:25:09 +10:00
symwalk.go Fix scan issue when encountering invalid symlinks (#871) 2020-10-20 17:00:23 +11:00
time.go Fix various generate issues (#1322) 2021-04-22 13:51:51 +10:00
user_agent.go Add User Agent to image download reqs (#1222) 2021-03-24 08:12:11 +11:00
vtt.go utils: vtt: test + rewrite (#1284) 2021-05-25 11:25:26 +10:00
vtt_test.go utils: vtt: test + rewrite (#1284) 2021-05-25 11:25:26 +10:00
windows.go Reorg 2019-02-14 15:42:52 -08:00