run-docs-build: build from tags dynamically instead of static list
PATCH v2 1/1 run-docs-build: build from tags dynamically instead of static list
Build Sphinx docs for all versions newer than yocto-3.1.5 inclusive. Integrate suggestions from Quentin Schulz and Nicolas Dechesne.
Signed-off-by Michael Halstead <[email protected]>
--- scripts/run-docs-build | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-)
scripts/run-docs-build +13 -7
@@ -77,13 +77,19 @@ for branch in dunfell gatesgarth hardknott; do done # Yocto Project releases/tags -for tag in 3.1.5 3.1.6 3.2 3.2.1 3.2.2 3.2.3; do - cd $ypdocs - git checkout yocto-$tag - make clean - make publish - mkdir $outputdir/$tag - cp -r ./_build/final/* $outputdir/$tag +v_sphinx='yocto-3.1.5' #This and newer versions have Sphinx docs. +cd $ypdocs +for tag in $(git tag --list 'yocto-*'); do + first=$(printf '%s\n%s' $tag $v_sphinx | sort --version-sort | head -n1) + if [ "$first" = "$v_sphinx" ]; then + cd $ypdocs + git checkout $tag + make clean + make publish + version=$(echo $tag | cut -c7-) + mkdir $outputdir/$version + cp -r ./_build/final/* $outputdir/$version + fi done # Update switchers.js with the copy from master ypdocs
Signature · 1 line
2.30.2