mirror of
git://git.yoctoproject.org/yocto-autobuilder-helper.git
synced 2025-07-19 20:59:02 +02:00
scripts/run-docs-build: Support auto generation of switchers.js and poky.yaml
This uses the set_versions.py script from the docs master branch to handle creation of the swictchers.js version information as well as the data in poky.yaml. This allows patches to those sections of the docs to be dropped. It is assumed the patch to use set_versions is applied to the docs transitions branch so that it's switchers.js files no longer need to be tweaked. This does lead to user visible changes on the website: - Older versioned released docs gain their current version and the latest version listed in the switcher rather than being unlisted - The list of releases is normally filtered down to our active ones (hardknott, honister and dev right now) - 3.3's doc references to gatesgath are corrected to hardknott - Docs for unversioned release branches (not linked on the website) now use 3.1.999 versioning instead of confusing them with the last relased version - 3.1.13 refers to 3.1.13 instead of 3.1.12 all of which seem to be reasonable improvements. The big advantage of these changes is that with a single change to the script in the master branch, the right thing should happen for all the current docs and at release time, only a docs rebuild should need to be triggered after tags are pushed. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
parent
6fd933fe06
commit
5946a6f028
|
@ -1,41 +0,0 @@
|
||||||
From 2e3ec94e906a255cd7b22dfca29a6148fc433732 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Michael Halstead <mhalstead@linuxfoundation.org>
|
|
||||||
Date: Wed, 16 Feb 2022 23:04:15 -0800
|
|
||||||
Subject: [PATCH 1/2] releases: update to include 3.1.14
|
|
||||||
|
|
||||||
Adding 3.1.14 to documentation switcher and release list.
|
|
||||||
|
|
||||||
Signed-off-by: Michael Halstead <mhalstead@linuxfoundation.org>
|
|
||||||
---
|
|
||||||
documentation/releases.rst | 1 +
|
|
||||||
documentation/sphinx-static/switchers.js | 2 +-
|
|
||||||
2 files changed, 2 insertions(+), 1 deletion(-)
|
|
||||||
|
|
||||||
diff --git a/documentation/releases.rst b/documentation/releases.rst
|
|
||||||
index 57e4566e1..affe63403 100644
|
|
||||||
--- a/documentation/releases.rst
|
|
||||||
+++ b/documentation/releases.rst
|
|
||||||
@@ -39,6 +39,7 @@ Release Series 3.1 (dunfell)
|
|
||||||
- :yocto_docs:`3.1.11 Documentation </3.1.11>`
|
|
||||||
- :yocto_docs:`3.1.12 Documentation </3.1.12>`
|
|
||||||
- :yocto_docs:`3.1.13 Documentation </3.1.13>`
|
|
||||||
+- :yocto_docs:`3.1.14 Documentation </3.1.14>`
|
|
||||||
|
|
||||||
==========================
|
|
||||||
Outdated Release Manuals
|
|
||||||
diff --git a/documentation/sphinx-static/switchers.js b/documentation/sphinx-static/switchers.js
|
|
||||||
index bda15485c..1d65fa7fa 100644
|
|
||||||
--- a/documentation/sphinx-static/switchers.js
|
|
||||||
+++ b/documentation/sphinx-static/switchers.js
|
|
||||||
@@ -6,7 +6,7 @@
|
|
||||||
'3.4.1': '3.4.1',
|
|
||||||
'3.3.4': '3.3.4',
|
|
||||||
'3.2.4': '3.2.4',
|
|
||||||
- '3.1.13': '3.1.13',
|
|
||||||
+ '3.1.14': '3.1.14',
|
|
||||||
'3.0.4': '3.0.4',
|
|
||||||
'2.7.4': '2.7.4',
|
|
||||||
};
|
|
||||||
--
|
|
||||||
2.35.1
|
|
||||||
|
|
|
@ -23,26 +23,3 @@ index 0d61afc9d..01d5e00c1 100644
|
||||||
bitbake_version = "1.46"
|
bitbake_version = "1.46"
|
||||||
|
|
||||||
# String used in sidebar
|
# String used in sidebar
|
||||||
diff --git a/documentation/poky.yaml b/documentation/poky.yaml
|
|
||||||
index 8da5f5915..e37ea420a 100644
|
|
||||||
--- a/documentation/poky.yaml
|
|
||||||
+++ b/documentation/poky.yaml
|
|
||||||
@@ -1,11 +1,11 @@
|
|
||||||
-DISTRO : "3.1.13"
|
|
||||||
+DISTRO : "3.1.14"
|
|
||||||
DISTRO_NAME_NO_CAP : "dunfell"
|
|
||||||
DISTRO_NAME : "Dunfell"
|
|
||||||
DISTRO_NAME_NO_CAP_MINUS_ONE : "zeus"
|
|
||||||
-YOCTO_DOC_VERSION : "3.1.13"
|
|
||||||
+YOCTO_DOC_VERSION : "3.1.14"
|
|
||||||
YOCTO_DOC_VERSION_MINUS_ONE : "3.0.4"
|
|
||||||
-DISTRO_REL_TAG : "yocto-3.1.13"
|
|
||||||
-POKYVERSION : "23.0.13"
|
|
||||||
+DISTRO_REL_TAG : "yocto-3.1.14"
|
|
||||||
+POKYVERSION : "23.0.14"
|
|
||||||
YOCTO_POKY : "poky-&DISTRO_NAME_NO_CAP;-&POKYVERSION;"
|
|
||||||
YOCTO_DL_URL : "https://downloads.yoctoproject.org"
|
|
||||||
YOCTO_AB_URL : "https://autobuilder.yoctoproject.org"
|
|
||||||
--
|
|
||||||
2.35.1
|
|
||||||
|
|
||||||
|
|
|
@ -25,56 +25,3 @@ index e42e7b18a..fc064bf32 100644
|
||||||
bitbake_version = "1.50"
|
bitbake_version = "1.50"
|
||||||
|
|
||||||
# String used in sidebar
|
# String used in sidebar
|
||||||
diff --git a/documentation/poky.yaml b/documentation/poky.yaml
|
|
||||||
index 30eb45379..32849bc70 100644
|
|
||||||
--- a/documentation/poky.yaml
|
|
||||||
+++ b/documentation/poky.yaml
|
|
||||||
@@ -1,12 +1,12 @@
|
|
||||||
-DISTRO : "3.3.4"
|
|
||||||
+DISTRO : "3.3.5"
|
|
||||||
DISTRO_NAME_NO_CAP : "hardknott"
|
|
||||||
DISTRO_NAME : "Hardknott"
|
|
||||||
DISTRO_NAME_NO_CAP_MINUS_ONE : "gatesgarth"
|
|
||||||
DISTRO_NAME_NO_CAP_LTS : "gatesgarth"
|
|
||||||
-YOCTO_DOC_VERSION : "3.3.4"
|
|
||||||
+YOCTO_DOC_VERSION : "3.3.5"
|
|
||||||
YOCTO_DOC_VERSION_MINUS_ONE : "3.2.4"
|
|
||||||
-DISTRO_REL_TAG : "yocto-3.3.4"
|
|
||||||
-POKYVERSION : "25.0.4"
|
|
||||||
+DISTRO_REL_TAG : "yocto-3.3.5"
|
|
||||||
+POKYVERSION : "25.0.5"
|
|
||||||
YOCTO_POKY : "poky-&DISTRO_NAME_NO_CAP;-&POKYVERSION;"
|
|
||||||
YOCTO_DL_URL : "https://downloads.yoctoproject.org"
|
|
||||||
YOCTO_AB_URL : "https://autobuilder.yoctoproject.org"
|
|
||||||
diff --git a/documentation/releases.rst b/documentation/releases.rst
|
|
||||||
index acee21d6b..1fb6054bc 100644
|
|
||||||
--- a/documentation/releases.rst
|
|
||||||
+++ b/documentation/releases.rst
|
|
||||||
@@ -10,6 +10,7 @@
|
|
||||||
|
|
||||||
- :yocto_docs:`3.4 Documentation </3.4>`
|
|
||||||
- :yocto_docs:`3.4.1 Documentation </3.4.1>`
|
|
||||||
+- :yocto_docs:`3.4.1 Documentation </3.4.2>`
|
|
||||||
|
|
||||||
*******************************
|
|
||||||
3.3 'hardknott' Release Series
|
|
||||||
@@ -20,6 +21,7 @@
|
|
||||||
- :yocto_docs:`3.3.2 Documentation </3.3.2>`
|
|
||||||
- :yocto_docs:`3.3.3 Documentation </3.3.3>`
|
|
||||||
- :yocto_docs:`3.3.4 Documentation </3.3.4>`
|
|
||||||
+- :yocto_docs:`3.3.5 Documentation </3.3.5>`
|
|
||||||
|
|
||||||
****************************
|
|
||||||
3.1 'dunfell' Release Series
|
|
||||||
@@ -38,6 +40,8 @@
|
|
||||||
- :yocto_docs:`3.1.10 Documentation </3.1.10>`
|
|
||||||
- :yocto_docs:`3.1.11 Documentation </3.1.11>`
|
|
||||||
- :yocto_docs:`3.1.12 Documentation </3.1.12>`
|
|
||||||
+- :yocto_docs:`3.1.13 Documentation </3.1.13>`
|
|
||||||
+- :yocto_docs:`3.1.14 Documentation </3.1.14>`
|
|
||||||
|
|
||||||
==========================
|
|
||||||
Previous Release Manuals
|
|
||||||
--
|
|
||||||
2.35.1
|
|
||||||
|
|
||||||
|
|
|
@ -29,20 +29,3 @@ index 5a2e25f7b..ab1b2b14c 100644
|
||||||
|
|
||||||
# String used in sidebar
|
# String used in sidebar
|
||||||
version = 'Version: ' + current_version
|
version = 'Version: ' + current_version
|
||||||
diff --git a/documentation/sphinx-static/switchers.js b/documentation/sphinx-static/switchers.js
|
|
||||||
index 7a4edc9e7..96efab2e8 100644
|
|
||||||
--- a/documentation/sphinx-static/switchers.js
|
|
||||||
+++ b/documentation/sphinx-static/switchers.js
|
|
||||||
@@ -2,7 +2,8 @@
|
|
||||||
'use strict';
|
|
||||||
|
|
||||||
var all_versions = {
|
|
||||||
- 'dev': 'dev (3.3)',
|
|
||||||
+ 'dev': 'dev (3.4)',
|
|
||||||
+ '3.3': '3.3',
|
|
||||||
'3.2.3': '3.2.3',
|
|
||||||
'3.1.6': '3.1.6',
|
|
||||||
'3.0.4': '3.0.4',
|
|
||||||
--
|
|
||||||
2.31.1
|
|
||||||
|
|
||||||
|
|
|
@ -24,70 +24,3 @@ index eff758a7b..ef369b7f1 100644
|
||||||
bitbake_version = "1.52"
|
bitbake_version = "1.52"
|
||||||
|
|
||||||
# String used in sidebar
|
# String used in sidebar
|
||||||
diff --git a/documentation/poky.yaml b/documentation/poky.yaml
|
|
||||||
index 392e3bd63..11e209e30 100644
|
|
||||||
--- a/documentation/poky.yaml
|
|
||||||
+++ b/documentation/poky.yaml
|
|
||||||
@@ -1,12 +1,12 @@
|
|
||||||
-DISTRO : "3.4"
|
|
||||||
+DISTRO : "3.4.1"
|
|
||||||
DISTRO_NAME_NO_CAP : "honister"
|
|
||||||
DISTRO_NAME : "Honister"
|
|
||||||
DISTRO_NAME_NO_CAP_MINUS_ONE : "hardknott"
|
|
||||||
DISTRO_NAME_NO_CAP_LTS : "dunfell"
|
|
||||||
-YOCTO_DOC_VERSION : "3.4"
|
|
||||||
+YOCTO_DOC_VERSION : "3.4.1"
|
|
||||||
YOCTO_DOC_VERSION_MINUS_ONE : "3.3.4"
|
|
||||||
-DISTRO_REL_TAG : "yocto-3.4"
|
|
||||||
-POKYVERSION : "26.0.0"
|
|
||||||
+DISTRO_REL_TAG : "yocto-3.4.1"
|
|
||||||
+POKYVERSION : "26.0.1"
|
|
||||||
YOCTO_POKY : "poky-&DISTRO_NAME_NO_CAP;-&POKYVERSION;"
|
|
||||||
YOCTO_DL_URL : "https://downloads.yoctoproject.org"
|
|
||||||
YOCTO_AB_URL : "https://autobuilder.yoctoproject.org"
|
|
||||||
diff --git a/documentation/releases.rst b/documentation/releases.rst
|
|
||||||
index a6c9a47b8..16ecbf712 100644
|
|
||||||
--- a/documentation/releases.rst
|
|
||||||
+++ b/documentation/releases.rst
|
|
||||||
@@ -4,6 +4,13 @@
|
|
||||||
Supported Release Manuals
|
|
||||||
===========================
|
|
||||||
|
|
||||||
+*****************************
|
|
||||||
+Release Series 3.4 (honister)
|
|
||||||
+*****************************
|
|
||||||
+
|
|
||||||
+- :yocto_docs:`3.4 Documentation </3.4>`
|
|
||||||
+- :yocto_docs:`3.4.1 Documentation </3.4.1>`
|
|
||||||
+
|
|
||||||
******************************
|
|
||||||
Release Series 3.3 (hardknott)
|
|
||||||
******************************
|
|
||||||
@@ -30,6 +37,7 @@ Release Series 3.1 (dunfell)
|
|
||||||
- :yocto_docs:`3.1.9 Documentation </3.1.9>`
|
|
||||||
- :yocto_docs:`3.1.10 Documentation </3.1.10>`
|
|
||||||
- :yocto_docs:`3.1.11 Documentation </3.1.11>`
|
|
||||||
+- :yocto_docs:`3.1.12 Documentation </3.1.12>`
|
|
||||||
|
|
||||||
==========================
|
|
||||||
Outdated Release Manuals
|
|
||||||
diff --git a/documentation/sphinx-static/switchers.js b/documentation/sphinx-static/switchers.js
|
|
||||||
index b15f5b3c1..056a8926b 100644
|
|
||||||
--- a/documentation/sphinx-static/switchers.js
|
|
||||||
+++ b/documentation/sphinx-static/switchers.js
|
|
||||||
@@ -3,10 +3,10 @@
|
|
||||||
|
|
||||||
var all_versions = {
|
|
||||||
'dev': 'dev (3.5)',
|
|
||||||
- '3.4': '3.4',
|
|
||||||
+ '3.4.1': '3.4.1',
|
|
||||||
'3.3.4': '3.3.4',
|
|
||||||
'3.2.4': '3.2.4',
|
|
||||||
- '3.1.11': '3.1.11',
|
|
||||||
+ '3.1.12': '3.1.12',
|
|
||||||
'3.0.4': '3.0.4',
|
|
||||||
'2.7.4': '2.7.4',
|
|
||||||
};
|
|
||||||
--
|
|
||||||
2.35.1
|
|
||||||
|
|
||||||
|
|
|
@ -1,63 +0,0 @@
|
||||||
From 3a72177f8ce5a52bece7d6d2f11514c47256a6f9 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Michael Halstead <mhalstead@linuxfoundation.org>
|
|
||||||
Date: Sun, 20 Feb 2022 19:33:01 -0800
|
|
||||||
Subject: [PATCH 1/2] releases: update to include 3.4.2
|
|
||||||
|
|
||||||
Adding 3.4.2 to documentation switcher and release list.
|
|
||||||
|
|
||||||
Signed-off-by: Michael Halstead <mhalstead@linuxfoundation.org>
|
|
||||||
---
|
|
||||||
documentation/poky.yaml | 8 ++++----
|
|
||||||
documentation/releases.rst | 1 +
|
|
||||||
documentation/sphinx-static/switchers.js | 2 +-
|
|
||||||
3 files changed, 6 insertions(+), 5 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/documentation/poky.yaml b/documentation/poky.yaml
|
|
||||||
index 11e209e30..058f76e50 100644
|
|
||||||
--- a/documentation/poky.yaml
|
|
||||||
+++ b/documentation/poky.yaml
|
|
||||||
@@ -1,12 +1,12 @@
|
|
||||||
-DISTRO : "3.4.1"
|
|
||||||
+DISTRO : "3.4.2"
|
|
||||||
DISTRO_NAME_NO_CAP : "honister"
|
|
||||||
DISTRO_NAME : "Honister"
|
|
||||||
DISTRO_NAME_NO_CAP_MINUS_ONE : "hardknott"
|
|
||||||
DISTRO_NAME_NO_CAP_LTS : "dunfell"
|
|
||||||
-YOCTO_DOC_VERSION : "3.4.1"
|
|
||||||
+YOCTO_DOC_VERSION : "3.4.2"
|
|
||||||
YOCTO_DOC_VERSION_MINUS_ONE : "3.3.4"
|
|
||||||
-DISTRO_REL_TAG : "yocto-3.4.1"
|
|
||||||
-POKYVERSION : "26.0.1"
|
|
||||||
+DISTRO_REL_TAG : "yocto-3.4.2"
|
|
||||||
+POKYVERSION : "26.0.2"
|
|
||||||
YOCTO_POKY : "poky-&DISTRO_NAME_NO_CAP;-&POKYVERSION;"
|
|
||||||
YOCTO_DL_URL : "https://downloads.yoctoproject.org"
|
|
||||||
YOCTO_AB_URL : "https://autobuilder.yoctoproject.org"
|
|
||||||
diff --git a/documentation/releases.rst b/documentation/releases.rst
|
|
||||||
index 16ecbf712..c4bfa857a 100644
|
|
||||||
--- a/documentation/releases.rst
|
|
||||||
+++ b/documentation/releases.rst
|
|
||||||
@@ -10,6 +10,7 @@ Release Series 3.4 (honister)
|
|
||||||
|
|
||||||
- :yocto_docs:`3.4 Documentation </3.4>`
|
|
||||||
- :yocto_docs:`3.4.1 Documentation </3.4.1>`
|
|
||||||
+- :yocto_docs:`3.4.2 Documentation </3.4.2>`
|
|
||||||
|
|
||||||
******************************
|
|
||||||
Release Series 3.3 (hardknott)
|
|
||||||
diff --git a/documentation/sphinx-static/switchers.js b/documentation/sphinx-static/switchers.js
|
|
||||||
index 056a8926b..c40823d8d 100644
|
|
||||||
--- a/documentation/sphinx-static/switchers.js
|
|
||||||
+++ b/documentation/sphinx-static/switchers.js
|
|
||||||
@@ -3,7 +3,7 @@
|
|
||||||
|
|
||||||
var all_versions = {
|
|
||||||
'dev': 'dev (3.5)',
|
|
||||||
- '3.4.1': '3.4.1',
|
|
||||||
+ '3.4.2': '3.4.2',
|
|
||||||
'3.3.4': '3.3.4',
|
|
||||||
'3.2.4': '3.2.4',
|
|
||||||
'3.1.12': '3.1.12',
|
|
||||||
--
|
|
||||||
2.35.1
|
|
||||||
|
|
|
@ -35,20 +35,3 @@ index 8e0847938..104b49ea0 100644
|
||||||
|
|
||||||
# String used in sidebar
|
# String used in sidebar
|
||||||
version = 'Version: ' + current_version
|
version = 'Version: ' + current_version
|
||||||
diff --git a/documentation/sphinx-static/switchers.js b/documentation/sphinx-static/switchers.js
|
|
||||||
index 1e37b625a..6038dbb5a 100644
|
|
||||||
--- a/documentation/sphinx-static/switchers.js
|
|
||||||
+++ b/documentation/sphinx-static/switchers.js
|
|
||||||
@@ -2,7 +2,8 @@
|
|
||||||
'use strict';
|
|
||||||
|
|
||||||
var all_versions = {
|
|
||||||
- 'dev': 'dev (3.4)',
|
|
||||||
+ 'dev': 'dev (3.5)',
|
|
||||||
+ '3.4': '3.4',
|
|
||||||
'3.3.3': '3.3.3',
|
|
||||||
'3.2.4': '3.2.4',
|
|
||||||
'3.1.11': '3.1.11',
|
|
||||||
--
|
|
||||||
2.31.1
|
|
||||||
|
|
||||||
|
|
|
@ -69,10 +69,11 @@ rsync -irlp --checksum --ignore-times --delete bitbake docs@docs.yoctoproject.or
|
||||||
|
|
||||||
cd $ypdocs
|
cd $ypdocs
|
||||||
|
|
||||||
|
# transition must build after master for the switchers.js file
|
||||||
# Again, keeping even the no longer supported releases (see above comment)
|
# Again, keeping even the no longer supported releases (see above comment)
|
||||||
first_sphinx_commit=01dd5af7954e24552aca022917669b27bb0541ed
|
first_sphinx_commit=01dd5af7954e24552aca022917669b27bb0541ed
|
||||||
first_dunfell_sphinx_commit=c25fe058b88b893b0d146f3ed27320b47cdec236
|
first_dunfell_sphinx_commit=c25fe058b88b893b0d146f3ed27320b47cdec236
|
||||||
for branch in dunfell transition $(git branch --remote --contains "$first_sphinx_commit" --format '%(refname:lstrip=3)') $(git tag --contains "$first_sphinx_commit" --contains "$first_dunfell_sphinx_commit" 'yocto-*'); do
|
for branch in dunfell $(git branch --remote --contains "$first_sphinx_commit" --format '%(refname:lstrip=3)') $(git tag --contains "$first_sphinx_commit" --contains "$first_dunfell_sphinx_commit" 'yocto-*') transition; do
|
||||||
if [ "$branch" = "HEAD" ]; then
|
if [ "$branch" = "HEAD" ]; then
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
|
@ -92,6 +93,20 @@ for branch in dunfell transition $(git branch --remote --contains "$first_sphinx
|
||||||
fi
|
fi
|
||||||
|
|
||||||
git checkout master releases.rst
|
git checkout master releases.rst
|
||||||
|
if [ -e poky.yaml ]; then
|
||||||
|
git checkout master sphinx-static/switchers.js.in
|
||||||
|
cp poky.yaml poky.yaml.in
|
||||||
|
git checkout master set_versions.py
|
||||||
|
case $branch in
|
||||||
|
yocto-*)
|
||||||
|
./set_versions.py $(echo "$branch" | sed 's/yocto-//')
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
./set_versions.py
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
|
||||||
make clean
|
make clean
|
||||||
make publish
|
make publish
|
||||||
|
|
||||||
|
@ -109,6 +124,7 @@ for branch in dunfell transition $(git branch --remote --contains "$first_sphinx
|
||||||
|
|
||||||
cp -r ./_build/final/* $outputdir/$branch
|
cp -r ./_build/final/* $outputdir/$branch
|
||||||
git reset --hard
|
git reset --hard
|
||||||
|
git clean -f
|
||||||
done
|
done
|
||||||
|
|
||||||
# get current release (e.g. most recent tag), and add a 'current' link
|
# get current release (e.g. most recent tag), and add a 'current' link
|
||||||
|
@ -116,9 +132,9 @@ tag=$(git tag --list 'yocto-*' | sort --version-sort | tail -1 | cut -c7-)
|
||||||
echo Linking to $tag as current
|
echo Linking to $tag as current
|
||||||
ln -s $tag $outputdir/current
|
ln -s $tag $outputdir/current
|
||||||
|
|
||||||
# Update switchers.js with the copy from master ypdocs
|
# Update bitbake switchers.js with the copy from master ypdocs
|
||||||
cd $outputdir
|
cd $outputdir/bitbake
|
||||||
find . -name switchers.js -not -path ./_static/switchers.js -exec cp ./_static/switchers.js {} \;
|
find . -name switchers.js -exec cp $outputdir/current/_static/switchers.js {} \;
|
||||||
|
|
||||||
cd $outputdir
|
cd $outputdir
|
||||||
rsync -irlp --checksum --ignore-times --delete . docs@docs.yoctoproject.org:docs/
|
rsync -irlp --checksum --ignore-times --delete . docs@docs.yoctoproject.org:docs/
|
||||||
|
|
Loading…
Reference in New Issue
Block a user