Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
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/update_docs.py
View
8 docs/management/commands/update_docs.py
@@ -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'))
subprocess.call("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.