From 7cf0eedaf799e8b7fc584b86c187f099c9b2891f Mon Sep 17 00:00:00 2001 From: Doug Hellmann Date: Tue, 1 Sep 2015 21:26:27 +0000 Subject: [PATCH] show more of the release summary in table Include the earliest release and the most recent release in the summary table at the top of each deliverable-type section. Change-Id: Ib0704f4639bc6e350a9587aefba2819b65128940 --- openstack_releases/sphinxext.py | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/openstack_releases/sphinxext.py b/openstack_releases/sphinxext.py index 78d4f89d8c..a454a5cbf1 100644 --- a/openstack_releases/sphinxext.py +++ b/openstack_releases/sphinxext.py @@ -149,19 +149,22 @@ class DeliverableDirective(rst.Directive): result.append('-' * len(title), source_name) result.append('', source_name) - # Build a table of the most recent version of each deliverable. + # Build a table of the first and most recent versions of each + # deliverable. most_recent = [] for deliverable_name, filename, deliverable_info in deliverables: - version = deliverable_info.get('releases', {})[-1].get( + earliest_version = deliverable_info.get('releases', {})[0].get( + 'version', 'unreleased') + recent_version = deliverable_info.get('releases', {})[-1].get( 'version', 'unreleased') ref = ':ref:`%s-%s`' % (series, deliverable_name) - most_recent.append((ref, version)) + most_recent.append((ref, earliest_version, recent_version)) _list_table( lambda t: result.append(t, source_name), - ['Deliverable', 'Version'], + ['Deliverable', 'Earliest Version', 'Most Recent Version'], most_recent, - title='Most Recent Releases', + title='Release Summary', ) # Show the detailed history of the deliverables within the series.