Adding translation mo files automatically on build (#65)

This commit is contained in:
Stan Triepels
2023-01-26 16:45:44 +01:00
committed by GitHub
parent 2f3b0d0a31
commit f9e01699c5
2 changed files with 13 additions and 0 deletions

View File

@@ -0,0 +1,9 @@
import subprocess
def generate_mo_files():
subprocess.run(["django-admin", "compilemessages"])
if __name__ == "__main__":
generate_mo_files()

View File

@@ -80,3 +80,7 @@ sentry = ["django-q-sentry"]
[tool.isort] [tool.isort]
profile = "black" profile = "black"
multi_line_output = 3 multi_line_output = 3
[tool.poetry.build]
generate-setup-file = false
script = "django_compilemessages.py"