-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(Locale): add localization support
- Loading branch information
1 parent
54d1c77
commit 095e336
Showing
16 changed files
with
2,237 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
# https://weblate.org/en/ | ||
|
||
ALL_LOCALES := en_US.po es_MX.po fr_FR.po | ||
|
||
# Update all locales from the 'messages.pot' template | ||
.PHONY: all | ||
all: $(ALL_LOCALES) | ||
|
||
# Generate a new locale file from the template | ||
.PHONY: generate | ||
generate: | ||
ifndef LOCALE | ||
$(error LOCALE not specified to generate) | ||
endif | ||
msginit --no-translator --input=messages.pot --locale=$(LOCALE) | ||
|
||
# Update the locale from the 'messages.pot' template | ||
$(ALL_LOCALES): messages.pot | ||
msgmerge --update --backup=none $@ $< |
Oops, something went wrong.