[libcxx-commits] [PATCH] D111926: [libc++][doc] Use sphinx variables to make updating the docs version easier
Tom Stellard via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Fri Oct 15 22:58:40 PDT 2021
tstellar created this revision.
tstellar added a reviewer: ldionne.
tstellar requested review of this revision.
Herald added a project: libc++.
Herald added a reviewer: libc++.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D111926
Files:
libcxx/docs/ReleaseNotes.rst
libcxx/docs/conf.py
Index: libcxx/docs/conf.py
===================================================================
--- libcxx/docs/conf.py
+++ libcxx/docs/conf.py
@@ -48,7 +48,8 @@
# built documents.
#
# The short X.Y version.
-version = '14.0.0'
+version_major = '14'
+version = version_major + '.0.0'
# The full version, including alpha/beta/rc tags.
release = version + 'git'
@@ -86,12 +87,14 @@
# A list of ignored prefixes for module index sorting.
#modindex_common_prefix = []
-in_progress = "(In-Progress) " if version != release else ""
+in_progress_title = "(In-Progress) " if version != release else ""
+in_progress = 'in-progress' if version != release else ""
-rst_epilog = """
+rst_epilog = f"""
.. |version| replace:: {version}
-.. |In Progress| replace:: {in_progress}
-
+.. |version_major| replace:: {version_major}
+.. |InProgressTitle| replace:: {in_progress_title}
+.. |InProgress| replace:: {in_progress}
"""
# -- Options for HTML output ---------------------------------------------------
Index: libcxx/docs/ReleaseNotes.rst
===================================================================
--- libcxx/docs/ReleaseNotes.rst
+++ libcxx/docs/ReleaseNotes.rst
@@ -1,6 +1,6 @@
-=========================================
-Libc++ |version| |In Progress|Release Notes
-=========================================
+================================================
+Libc++ |version| |InProgressTitle| Release Notes
+================================================
.. contents::
:local:
@@ -10,7 +10,7 @@
.. warning::
- These are in-progress notes for the upcoming libc++ 14 release.
+ These are |InProgress| notes for the upcoming libc++ |version_major| release.
Release notes for previous releases can be found on
`the Download Page <https://releases.llvm.org/download.html>`_.
@@ -18,7 +18,7 @@
============
This document contains the release notes for the libc++ C++ Standard Library,
-part of the LLVM Compiler Infrastructure, release 14.0.0. Here we describe the
+part of the LLVM Compiler Infrastructure, release |version|. Here we describe the
status of libc++ in some detail, including major improvements from the previous
release and new feature work. For the general LLVM release notes, see `the LLVM
documentation <https://llvm.org/docs/ReleaseNotes.html>`_. All LLVM releases may
@@ -33,7 +33,7 @@
see the `releases page <https://llvm.org/releases/>`_.
What's New in Libc++ |version|?
-============================
+===============================
New Features
------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D111926.380141.patch
Type: text/x-patch
Size: 2538 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20211016/49dcdada/attachment-0001.bin>
More information about the libcxx-commits
mailing list