diff options
| author | Claude Paroz <claude@2xlibre.net> | 2014-04-23 15:13:15 +0200 |
|---|---|---|
| committer | Claude Paroz <claude@2xlibre.net> | 2014-04-23 15:16:38 +0200 |
| commit | 0424c84d541d7b0e23783c33c2db495543e3bd47 (patch) | |
| tree | 3e84fbb2702c53017d6e62f47a1f6a823da5baa5 | |
| parent | 07235aec9d0853b4fa58629c572912786b6270c9 (diff) | |
[1.7.x] Set compile messages options as class variable
Refs #18714. Same logic as options for makemessages commands.
Backport of 3a435a057 from master.
| -rw-r--r-- | django/core/management/commands/compilemessages.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/django/core/management/commands/compilemessages.py b/django/core/management/commands/compilemessages.py index 0e55a28888..eaba797aad 100644 --- a/django/core/management/commands/compilemessages.py +++ b/django/core/management/commands/compilemessages.py @@ -37,7 +37,9 @@ class Command(BaseCommand): requires_system_checks = False leave_locale_alone = True + program = 'msgfmt' + program_options = ['--check-format'] def handle(self, **options): locale = options.get('locale') @@ -92,7 +94,7 @@ class Command(BaseCommand): "writable location. mo files will not be updated/created." % dirpath) return - args = [self.program, '--check-format', '-o', + args = [self.program] + self.program_options + ['-o', npath(base_path + '.mo'), npath(base_path + '.po')] output, errors, status = popen_wrapper(args) if status: |
