Update translate task (#5283)

- Allow for skipping of building static files
- CI workflow does not have node / etc / installed
This commit is contained in:
Oliver 2023-07-19 10:43:40 +10:00 committed by GitHub
parent d012f8f08c
commit cd3d3834be
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 3 deletions

View File

@ -34,7 +34,7 @@ jobs:
invoke install
- name: Make Translations
run: |
invoke translate
invoke translate --skip-static
- name: Commit files
run: |
git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com"

View File

@ -223,8 +223,8 @@ def translate_stats(c):
c.run(f'python3 {path}')
@task(post=[translate_stats, static])
def translate(c):
@task(post=[translate_stats])
def translate(c, skip_static=False):
"""Rebuild translation source files. Advanced use only!
Note: This command should not be used on a local install,
@ -234,6 +234,10 @@ def translate(c):
manage(c, "makemessages --all -e py,html,js --no-wrap")
manage(c, "compilemessages")
if not skip_static:
# Update static files
static(c)
@task
def backup(c):