Publish to publish-docs/html

Publish to publish-docs/html to simplify our doc building and publishing
CI jobs.

Change-Id: I8beb68195a7beaa3f2c125ef83db0fa589837639
This commit is contained in:
Andreas Jaeger 2019-08-15 06:24:32 +02:00
parent 06d7ac27b7
commit a031fd772e
4 changed files with 11 additions and 7 deletions

View File

@ -18,7 +18,7 @@ if [ -z "$DIRECTORY" ] ; then
echo "usage $0 DIRECTORY options" echo "usage $0 DIRECTORY options"
echo "Options are:" echo "Options are:"
echo "--tag TAG: Use given tag for building" echo "--tag TAG: Use given tag for building"
echo "--target TARGET: Copy files to publish-docs/$TARGET" echo "--target TARGET: Copy files to publish-docs/html/$TARGET"
echo "--build BUILD: Name of build directory" echo "--build BUILD: Name of build directory"
echo "--linkcheck: Check validity of links instead of building" echo "--linkcheck: Check validity of links instead of building"
echo "--pdf: PDF file generation" echo "--pdf: PDF file generation"
@ -105,9 +105,9 @@ else
# Copy RST (and PDF) # Copy RST (and PDF)
if [ "$TARGET" != "" ] ; then if [ "$TARGET" != "" ] ; then
mkdir -p publish-docs/$TARGET mkdir -p publish-docs/html/$TARGET
rsync -a $BUILD_DIR/ publish-docs/$TARGET/ rsync -a $BUILD_DIR/ publish-docs/html/$TARGET/
# Remove unneeded build artefact # Remove unneeded build artefact
rm -f publish-docs/$TARGET/.buildinfo rm -f publish-docs/html/$TARGET/.buildinfo
fi fi
fi fi

View File

@ -96,7 +96,7 @@ function build_rst {
-d ${DOCTREES} \ -d ${DOCTREES} \
${DOC_DIR}${book}/source/ \ ${DOC_DIR}${book}/source/ \
${BUILD_DIR} ${BUILD_DIR}
PUBLISH_DIR=publish-docs/${language}/${book}-${tag} PUBLISH_DIR=publish-docs/html/${language}/${book}-${tag}
mkdir -p ${PUBLISH_DIR} mkdir -p ${PUBLISH_DIR}
rsync -a ${DOC_DIR}${book}/build-${tag}/html/ ${PUBLISH_DIR} rsync -a ${DOC_DIR}${book}/build-${tag}/html/ ${PUBLISH_DIR}
echo $MARKER_TEXT > ${PUBLISH_DIR}/.root-marker echo $MARKER_TEXT > ${PUBLISH_DIR}/.root-marker
@ -109,7 +109,7 @@ function build_rst {
-d ${DOCTREES} \ -d ${DOCTREES} \
${DOC_DIR}${book}/source/ \ ${DOC_DIR}${book}/source/ \
${BUILD_DIR} ${BUILD_DIR}
PUBLISH_DIR=publish-docs/${language}/${book}/ PUBLISH_DIR=publish-docs/html/${language}/${book}/
mkdir -p ${PUBLISH_DIR} mkdir -p ${PUBLISH_DIR}
rsync -a ${DOC_DIR}${book}/build/html/ ${PUBLISH_DIR} rsync -a ${DOC_DIR}${book}/build/html/ ${PUBLISH_DIR}
echo $MARKER_TEXT > ${PUBLISH_DIR}/.root-marker echo $MARKER_TEXT > ${PUBLISH_DIR}/.root-marker

View File

@ -83,7 +83,7 @@ OPTIONS
check-build. check-build.
**--publish** **--publish**
Setup content in publish-docs directory for publishing to Setup content in publish-docs/html directory for publishing to
external website. external website.
**--verbose** **--verbose**

View File

@ -0,0 +1,4 @@
critical:
- |
Change publishing from `publish-docs` to `publish-docs/html`. This needs
changing in build and publish CI jobs.