Skip to content

Commit

Permalink
feat: standardize make extract_translations (#232)
Browse files Browse the repository at this point in the history
* Create translation directory conf/locale. This is the default used one in openedx-translations
* Remove locale directory. It's not actually used. It was added when completion is stripped out of edx-platform, there is no local translation, and there is no translation project named completion in transifex
* Update make extract_translations to use django-admin instead of manage.py

Refs: FC-0012 OEP-58
  • Loading branch information
shadinaif authored May 9, 2023
1 parent 4a30f93 commit c9ca88d
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 75 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ htmlcov/

# Translations
*.mo
completion/conf/locale/*/LC_MESSAGES/*

# IDEs and text editors
*~
Expand Down
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -86,11 +86,11 @@ selfcheck: ## check that the Makefile is well-formed

extract_translations: ## extract strings to be translated, outputting .mo files
rm -rf docs/_build
cd completion && ../manage.py makemessages -l en -v1 -d django
cd completion && ../manage.py makemessages -l en -v1 -d djangojs
cd completion && django-admin makemessages -l en -v1 -d django
cd completion && django-admin makemessages -l en -v1 -d djangojs

compile_translations: ## compile translation files, outputting .po files for each supported language
cd completion && ../manage.py compilemessages
cd completion && django-admin compilemessages

detect_changed_source_translations:
cd completion && i18n_tool changed
Expand Down
4 changes: 4 additions & 0 deletions completion/conf/locale/config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Configuration for i18n workflow.

locales:
- en # English - Source Language
72 changes: 0 additions & 72 deletions locale/config.yaml

This file was deleted.

0 comments on commit c9ca88d

Please sign in to comment.