Skip to content
This repository
Browse code

added makemessages script

  • Loading branch information...
commit 71919c6b7483490dbbe420acff3f7e24ecfc0e52 1 parent 35d65c5
Jonas Obrist ojii authored

Showing 1 changed file with 25 additions and 0 deletions. Show diff stats Hide diff stats

  1. +25 0 makemessages.py
25 makemessages.py
... ... @@ -0,0 +1,25 @@
  1 +#!/usr/bin/env python
  2 +from cms.test_utils.cli import configure
  3 +from cms.test_utils.tmpdir import temp_dir
  4 +import os
  5 +
  6 +def main():
  7 + with temp_dir() as STATIC_ROOT:
  8 + with temp_dir() as MEDIA_ROOT:
  9 + configure(
  10 + ROOT_URLCONF='cms.test_utils.project.urls',
  11 + STATIC_ROOT=STATIC_ROOT,
  12 + MEDIA_ROOT=MEDIA_ROOT,
  13 + DATABASES = {
  14 + 'default': {
  15 + 'ENGINE': 'django.db.backends.sqlite3',
  16 + 'NAME': 'cmstestdb.sqlite',
  17 + }
  18 + }
  19 + )
  20 + from django.core.management import call_command
  21 + os.chdir('cms')
  22 + call_command('makemessages', all=True)
  23 +
  24 +if __name__ == '__main__':
  25 + main()

0 comments on commit 71919c6

Please sign in to comment.
Something went wrong with that request. Please try again.