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
This commit is contained in:
parent
e722bb8efc
commit
a9b1818223
|
@ -13,6 +13,8 @@
|
||||||
# under the License.
|
# under the License.
|
||||||
|
|
||||||
BUILD_FAIL=0
|
BUILD_FAIL=0
|
||||||
|
INSTALL_TAGS="obs rdo ubuntu debian debconf"
|
||||||
|
FIRSTAPP_TAGS="libcloud dotnet fog openstacksdk pkgcloud shade"
|
||||||
|
|
||||||
function build_rst {
|
function build_rst {
|
||||||
language=$1
|
language=$1
|
||||||
|
@ -83,7 +85,7 @@ function build_rst {
|
||||||
# Build all books
|
# Build all books
|
||||||
if [ ${book} = "firstapp" ] ; then
|
if [ ${book} = "firstapp" ] ; then
|
||||||
# Firstapp has several variations, build all of them
|
# 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"
|
BUILD_DIR="${DOC_DIR}${book}/build-${tag}/html"
|
||||||
DOCTREES="${BUILD_DIR}.doctrees"
|
DOCTREES="${BUILD_DIR}.doctrees"
|
||||||
tox -evenv "sphinx-build -q -E \
|
tox -evenv "sphinx-build -q -E \
|
||||||
|
@ -97,7 +99,6 @@ function build_rst {
|
||||||
done
|
done
|
||||||
elif [ ${book} = "install-guide" ] ; then
|
elif [ ${book} = "install-guide" ] ; then
|
||||||
# Install Guide has several variations, build all of them
|
# Install Guide has several variations, build all of them
|
||||||
TAGS="obs rdo ubuntu debian debconf"
|
|
||||||
INDEX=${DOC_DIR}${book}/source/index.rst
|
INDEX=${DOC_DIR}${book}/source/index.rst
|
||||||
|
|
||||||
# For translation work, we should have only one index file,
|
# For translation work, we should have only one index file,
|
||||||
|
@ -110,7 +111,7 @@ function build_rst {
|
||||||
cp -f ${INDEX} ${INDEX}.save
|
cp -f ${INDEX} ${INDEX}.save
|
||||||
trap "mv -f ${INDEX}.save ${INDEX}" EXIT
|
trap "mv -f ${INDEX}.save ${INDEX}" EXIT
|
||||||
|
|
||||||
for tag in $TAGS; do
|
for tag in $INSTALL_TAGS; do
|
||||||
if [[ "$tag" == "debconf" ]]; then
|
if [[ "$tag" == "debconf" ]]; then
|
||||||
# Build the guide with debconf
|
# Build the guide with debconf
|
||||||
# To use debian only contents, use "debian" tag.
|
# 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
|
rmdir --ignore-fail-on-non-empty publish-docs/$language/draft
|
||||||
;;
|
;;
|
||||||
firstapp)
|
firstapp)
|
||||||
for tag in libcloud dotnet fog openstacksdk pkgcloud shade; do
|
for tag in $FIRSTAPP_TAGS; do
|
||||||
mv publish-docs/$language/$book-${tag} \
|
mv publish-docs/$language/$book-${tag} \
|
||||||
publish-docs/draft/$language/$book-${tag}
|
publish-docs/draft/$language/$book-${tag}
|
||||||
done
|
done
|
||||||
rmdir --ignore-fail-on-non-empty publish-docs/$language/
|
rmdir --ignore-fail-on-non-empty publish-docs/$language/
|
||||||
;;
|
;;
|
||||||
install-guide)
|
install-guide)
|
||||||
for tag in obs rdo ubuntu ; do
|
for tag in $INSTALL_TAGS ; do
|
||||||
mv publish-docs/$language/$book-${tag} \
|
mv publish-docs/$language/$book-${tag} \
|
||||||
publish-docs/draft/$language/$book-${tag}
|
publish-docs/draft/$language/$book-${tag}
|
||||||
done
|
done
|
||||||
|
|
Loading…
Reference in New Issue