Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Browse files

Build pot files (gettext target) for the default release

This will allow us to direct Transifex to the ever up-to-date source
of pot files. Previously, we were manually committing updated pot
files from time to time in the django-docs-translations repository.
  • Loading branch information...
commit 4d360c21a15de6d7540c94ea2d2bd8b48f15ae58 1 parent aa64079
@claudep claudep authored
Showing with 7 additions and 1 deletion.
  1. +7 −1 docs/management/commands/
8 docs/management/commands/
@@ -36,6 +36,8 @@ def handle_noargs(self, **kwargs):
except (KeyError, TypeError, ValueError):
verbosity = 1
+ builders = ['json', 'html']
# Somehow, bizarely, there's a bug in Sphinx such that if I try to
# build 1.0 before other versions, things fail in weird ways. However,
# building newer versions first works. I suspect Sphinx is hanging onto
@@ -76,10 +78,14 @@ def handle_noargs(self, **kwargs):
source_dir.child('locale').write_link(trans_dir.child('translations'))"cd %s && make translations" % trans_dir, shell=True)
+ if release.is_default:
+ # Build the pot files (later retrieved by Transifex)
+ builders.append('gettext')
# Use Sphinx to build the release docs into JSON and HTML documents.
- for builder in ('json', 'html'):
+ for builder in builders:
# Wipe and re-create the build directory. See #18930.
build_dir = parent_build_dir.child('_build', builder)
if build_dir.exists():
Please sign in to comment.
Something went wrong with that request. Please try again.