Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add config option to define what languages are enabled. #5590

Merged
merged 5 commits into from
Jan 12, 2022

Conversation

Warriorrrr
Copy link
Member

Description:

Adds a new enabled-langs config option, that users can use to define what languages are enabled.


New Nodes/Commands/ConfigOptions:


Relevant Towny Issue ticket:


  • I have tested this pull request for defects on a server.

By making this pull request, I represent that I have the right to waive copyright and related rights to my contribution, and agree that all copyright and related rights in my contributions are waived, and I acknowledge that the TownyAdvanced organization has the copyright to use and modify my contribution under the Towny License for perpetuity.

@Warriorrrr Warriorrrr force-pushed the feature/enabled-langs branch from 546d3e7 to ab7bc3f Compare January 11, 2022 23:40
Warriorrrr and others added 3 commits January 12, 2022 01:16
- Skips putting the invalid languages into memory at all, filtering out
invalid languages from being loaded, made into reference files and being
loaded into the override langs.
- Removes unused imports in TownBlockTypeHandler.
- Adds config comments explaining how to enter in enabled languages.
- Add code to filter out .yml in locales when people invariably skip
reading the above comments.
Filter out undesired languages in the TranslationLoader
@LlmDl LlmDl merged commit 1aafcbb into master Jan 12, 2022
@LlmDl LlmDl deleted the feature/enabled-langs branch January 12, 2022 16:13
LlmDl added a commit that referenced this pull request Jan 12, 2022
Warriorrrr with PR #5590.
  - New Config Option: language.enabled_languages
    - Default: *
    - The languages you wish to have enabled. Set to '*' to use all
available languages.
    - If you would like to only allow 4 languages use:
en-US,ru-RU,es-ES,fr-FR
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants