From a9b18182238cf8b1f860de414a44d46ff8e69b2c Mon Sep 17 00:00:00 2001 From: Andreas Jaeger Date: Mon, 29 Aug 2016 12:41:38 +0200 Subject: [PATCH] Fix install-guide draft translated publishing Use a central TAGS variable for install-guide and use it everywhere. We missed debian and debconf in one place and thus publish that translated content in the wrong place. Do the same change for first-app. Change-Id: I2f9605f8632f746cb16b0a8ee241f68a311e2855 --- bin/doc-tools-check-languages | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/bin/doc-tools-check-languages b/bin/doc-tools-check-languages index f05cada4..3cc862a7 100755 --- a/bin/doc-tools-check-languages +++ b/bin/doc-tools-check-languages @@ -13,6 +13,8 @@ # under the License. BUILD_FAIL=0 +INSTALL_TAGS="obs rdo ubuntu debian debconf" +FIRSTAPP_TAGS="libcloud dotnet fog openstacksdk pkgcloud shade" function build_rst { language=$1 @@ -83,7 +85,7 @@ function build_rst { # Build all books if [ ${book} = "firstapp" ] ; then # Firstapp has several variations, build all of them - for tag in libcloud dotnet fog openstacksdk pkgcloud shade; do + for tag in $FIRSTAPP_TAGS ; do BUILD_DIR="${DOC_DIR}${book}/build-${tag}/html" DOCTREES="${BUILD_DIR}.doctrees" tox -evenv "sphinx-build -q -E \ @@ -97,7 +99,6 @@ function build_rst { done elif [ ${book} = "install-guide" ] ; then # Install Guide has several variations, build all of them - TAGS="obs rdo ubuntu debian debconf" INDEX=${DOC_DIR}${book}/source/index.rst # For translation work, we should have only one index file, @@ -110,7 +111,7 @@ function build_rst { cp -f ${INDEX} ${INDEX}.save trap "mv -f ${INDEX}.save ${INDEX}" EXIT - for tag in $TAGS; do + for tag in $INSTALL_TAGS; do if [[ "$tag" == "debconf" ]]; then # Build the guide with debconf # To use debian only contents, use "debian" tag. @@ -223,14 +224,14 @@ function handle_draft_language { rmdir --ignore-fail-on-non-empty publish-docs/$language/draft ;; firstapp) - for tag in libcloud dotnet fog openstacksdk pkgcloud shade; do + for tag in $FIRSTAPP_TAGS; do mv publish-docs/$language/$book-${tag} \ publish-docs/draft/$language/$book-${tag} done rmdir --ignore-fail-on-non-empty publish-docs/$language/ ;; install-guide) - for tag in obs rdo ubuntu ; do + for tag in $INSTALL_TAGS ; do mv publish-docs/$language/$book-${tag} \ publish-docs/draft/$language/$book-${tag} done