diff options
| author | 2021-02-03 19:17:00 -0500 | |
|---|---|---|
| committer | 2021-02-03 19:17:00 -0500 | |
| commit | 3a0d66f07b112b6d2bdc2b57bbf717a89a351ce6 (patch) | |
| tree | a7cf56282e54f05785243bc1e903d6594f2c06ba /scripts/langmatrix.py | |
| parent | 787b97a4cb24330b36f11297c6d3a7a473a907d0 (diff) | |
New upstream version 8.1.2.upstream/8.1.2
Diffstat (limited to 'scripts/langmatrix.py')
| -rwxr-xr-x | scripts/langmatrix.py | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/scripts/langmatrix.py b/scripts/langmatrix.py new file mode 100755 index 0000000..357ddea --- /dev/null +++ b/scripts/langmatrix.py @@ -0,0 +1,20 @@ +#!/usr/bin/env python3 +"""A matrix! Of languages!""" +import nikola.nikola + +keys = ['LUXON_LOCALES', 'MOMENTJS_LOCALES', 'PYPHEN_LOCALES', 'DOCUTILS_LOCALES'] +keys_short = ['language', 'luxon', 'moment', 'pyphen', 'docutils'] +print('\t'.join(keys_short)) + +for tr in nikola.nikola.LEGAL_VALUES['TRANSLATIONS']: + if isinstance(tr, tuple): + tr = tr[0] + out = tr + if len(out) < 8: + out += '\t' + for key in keys: + out += '\t' + out += '\x1b[37;42;1m+' if tr in nikola.nikola.LEGAL_VALUES[key] else '\x1b[37;41;1m-' + print(out + '\t\x1b[0m') + +print('\t'.join(keys_short)) |
