diff options
author | Mike Bayer <mike_mp@zzzcomputing.com> | 2012-10-20 21:24:00 -0400 |
---|---|---|
committer | Mike Bayer <mike_mp@zzzcomputing.com> | 2012-10-20 21:24:00 -0400 |
commit | f2bc0ddcb496e6a0cb0a0ad88c7c055dbf0c11a7 (patch) | |
tree | 31e767271f054aa1a45a93eb2c08ba8e37f92371 | |
parent | ccd5d7564ebd484b15cdc7bc27ed2f4a667a9440 (diff) | |
download | sqlalchemy-f2bc0ddcb496e6a0cb0a0ad88c7c055dbf0c11a7.tar.gz |
updated changelog thing
-rw-r--r-- | doc/build/builder/changelog.py | 20 | ||||
-rw-r--r-- | doc/build/builder/mako.py | 6 | ||||
-rw-r--r-- | doc/build/conf.py | 3 |
3 files changed, 18 insertions, 11 deletions
diff --git a/doc/build/builder/changelog.py b/doc/build/builder/changelog.py index 38ec235db..24ceaeaa3 100644 --- a/doc/build/builder/changelog.py +++ b/doc/build/builder/changelog.py @@ -153,12 +153,19 @@ class ChangeLogDirective(EnvDirective, Directive): insert_ticket.append(nodes.Text(", ", ", ")) else: insert_ticket.append(nodes.Text(" ", " ")) - insert_ticket.append( - nodes.reference('', '', - nodes.Text("#%s" % ticket, "#%s" % ticket), - refuri=self.env.config.changelog_render_ticket(ticket) + refuri = self.env.config.changelog_render_ticket + if refuri is not None: + refuri = refuri % ticket + insert_ticket.append( + nodes.reference('', '', + nodes.Text("#%s" % ticket, "#%s" % ticket), + refuri=refuri + ) + ) + else: + insert_ticket.append( + nodes.Text("#%s" % ticket, "#%s" % ticket) ) - ) if rec['tags']: tag_node = nodes.strong('', @@ -217,5 +224,6 @@ def setup(app): app.add_config_value("changelog_sections", [], 'env') app.add_config_value("changelog_inner_tag_sort", [], 'env') app.add_config_value("changelog_render_ticket", - lambda ticket: ticket, 'env' + None, + 'env' ) diff --git a/doc/build/builder/mako.py b/doc/build/builder/mako.py index 2d3dc03e3..845686afc 100644 --- a/doc/build/builder/mako.py +++ b/doc/build/builder/mako.py @@ -76,7 +76,7 @@ class MakoBridge(TemplateBridge): def setup(app): app.config['template_bridge'] = "builder.mako.MakoBridge" - app.add_config_value('release_date', "", True) - app.add_config_value('site_base', "", True) - app.add_config_value('build_number', "", 1) + app.add_config_value('release_date', "", 'env') + app.add_config_value('site_base', "", 'env') + app.add_config_value('build_number', "", 'env') diff --git a/doc/build/conf.py b/doc/build/conf.py index a6c333c02..9e2749888 100644 --- a/doc/build/conf.py +++ b/doc/build/conf.py @@ -61,8 +61,7 @@ changelog_sections = ["general", "orm", "orm declarative", "orm querying", \ changelog_inner_tag_sort = ["feature", "bug", "moved", "changed", "removed"] # how to render a ticket link -def changelog_render_ticket(ticket): - return "http://www.sqlalchemy.org/trac/ticket/%s" % ticket +changelog_render_ticket = "http://www.sqlalchemy.org/trac/ticket/%s" # The encoding of source files. |