Skip to content

Commit

Permalink
feat: standardize make extract_translations (#212)
Browse files Browse the repository at this point in the history
* Delete `locale` directory as it's not needed
* Fix the translation command `make extract_translations` to use `django-admin` instead of `manage.py`. And fix `cd edx-ace` to the correct path `cd edx_ace`

Refs: FC-0012 OEP-58
  • Loading branch information
shadinaif authored May 9, 2023
1 parent 1e293dd commit db15604
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 76 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -71,3 +71,6 @@ edx_ace/tests/__init__.py
default.db

.hypothesis

# Translation
edx_ace/conf/locale/*/LC_MESSAGES/*
8 changes: 4 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -88,14 +88,14 @@ write-pylintrc:

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

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

detect_changed_source_translations:
cd edx-ace && i18n_tool changed
cd edx_ace && i18n_tool changed

pull_translations: ## pull translations from Transifex
tx pull -t -a -f --mode reviewed
Expand Down
72 changes: 0 additions & 72 deletions locale/config.yaml

This file was deleted.

0 comments on commit db15604

Please sign in to comment.