Rename common-rst to common
Keep the sync target repo path "common-rst" as of now. Change-Id: I552d2c0a422c4824632b11fa273629004b889306
@ -25,6 +25,8 @@ DOC_DIR="doc/"
|
||||
# Values need to match content in
|
||||
# project-config/jenkins/scripts/common_translation_update.sh
|
||||
declare -A SPECIAL_BOOKS=(
|
||||
# This needs special handling, handle it with the RST tools.
|
||||
["common"]="RST"
|
||||
["admin-guide-cloud"]="RST"
|
||||
["arch-design"]="RST"
|
||||
["config-reference"]="RST"
|
||||
@ -35,10 +37,7 @@ declare -A SPECIAL_BOOKS=(
|
||||
["user-guide-admin"]="RST"
|
||||
# Do not translate
|
||||
["cli-reference"]="skip"
|
||||
["common"]="skip"
|
||||
["contributor-guide"]="skip"
|
||||
# Skip arch design while its being revised
|
||||
["arch-design-draft"]="skip"
|
||||
# This needs special handling, handle it with the RST tools.
|
||||
["common-rst"]="RST"
|
||||
)
|
||||
|
@ -1 +1 @@
|
||||
../../common-rst
|
||||
../../common
|
@ -1 +1 @@
|
||||
../../common-rst
|
||||
../../common
|
@ -1 +1 @@
|
||||
../../common-rst
|
||||
../../common
|
@ -1 +1 @@
|
||||
../../common-rst/
|
||||
../../common
|
Before Width: | Height: | Size: 220 KiB After Width: | Height: | Size: 220 KiB |
Before Width: | Height: | Size: 120 KiB After Width: | Height: | Size: 120 KiB |
Before Width: | Height: | Size: 54 KiB After Width: | Height: | Size: 54 KiB |
Before Width: | Height: | Size: 35 KiB After Width: | Height: | Size: 35 KiB |
Before Width: | Height: | Size: 72 KiB After Width: | Height: | Size: 72 KiB |
Before Width: | Height: | Size: 39 KiB After Width: | Height: | Size: 39 KiB |
Before Width: | Height: | Size: 32 KiB After Width: | Height: | Size: 32 KiB |
Before Width: | Height: | Size: 131 KiB After Width: | Height: | Size: 131 KiB |
Before Width: | Height: | Size: 229 KiB After Width: | Height: | Size: 229 KiB |
Before Width: | Height: | Size: 238 KiB After Width: | Height: | Size: 238 KiB |
Before Width: | Height: | Size: 77 KiB After Width: | Height: | Size: 77 KiB |
Before Width: | Height: | Size: 72 KiB After Width: | Height: | Size: 72 KiB |
@ -56,7 +56,7 @@ master_doc = 'index'
|
||||
|
||||
# General information about the project.
|
||||
project = u'Common documents'
|
||||
bug_tag = u'common-rst'
|
||||
bug_tag = u'common'
|
||||
|
||||
copyright = u'2015-2016, OpenStack contributors'
|
||||
|
||||
@ -74,7 +74,7 @@ release = '1.0.0'
|
||||
# gitsha: The SHA checksum of the bug description. Automatically extracted from git log.
|
||||
# bug_tag: Tag for categorizing the bug. Must be set manually.
|
||||
# These variables are passed to the logabug code via html_context.
|
||||
giturl = u'http://git.openstack.org/cgit/openstack/openstack-manuals/tree/doc/common-rst/source'
|
||||
giturl = u'http://git.openstack.org/cgit/openstack/openstack-manuals/tree/doc/common/source'
|
||||
git_cmd = "/usr/bin/git log | head -n1 | cut -f2 -d' '"
|
||||
gitsha = os.popen(git_cmd).read().strip('\n')
|
||||
html_context = {"gitsha": gitsha, "bug_tag": bug_tag,
|
@ -1 +1 @@
|
||||
../../common-rst
|
||||
../../common
|
@ -1 +1 @@
|
||||
../../common-rst/
|
||||
../../common
|
@ -1 +1 @@
|
||||
../../common-rst/
|
||||
../../common
|
@ -1 +1 @@
|
||||
../../common-rst
|
||||
../../common
|
@ -1 +1 @@
|
||||
../../common-rst
|
||||
../../common
|
@ -1 +1 @@
|
||||
../../common-rst
|
||||
../../common
|
@ -1 +1 @@
|
||||
../../common-rst
|
||||
../../common
|
@ -24,7 +24,7 @@ trap "mv -f ${INDEX}.save ${INDEX}" EXIT
|
||||
|
||||
for tag in $TAGS; do
|
||||
GLOSSARY=""
|
||||
if [[ ! -e doc/common-rst/glossary.rst ]] ; then
|
||||
if [[ ! -e doc/common/glossary.rst ]] ; then
|
||||
GLOSSARY="--glossary"
|
||||
fi
|
||||
|
||||
|
@ -67,7 +67,7 @@ done
|
||||
|
||||
if [ "$GLOSSARY" -eq "1" ] ; then
|
||||
echo "Generating Glossary"
|
||||
tools/glossary2rst.py doc/common-rst/glossary.rst
|
||||
tools/glossary2rst.py doc/common/glossary.rst
|
||||
fi
|
||||
|
||||
if [ -z "$BUILD" ] ; then
|
||||
|
@ -35,16 +35,16 @@ else
|
||||
NUMBER_OF_CORES=2
|
||||
fi
|
||||
|
||||
# common-rst is imported from various RST documents, but what files are
|
||||
# common is imported from various RST documents, but what files are
|
||||
# used varies across RST documents. Thus we need an index file to include
|
||||
# all files under common-rst. To this aim, we create such document called
|
||||
# 'common-rst-work' dynamically to generate the POT file of common-rst.
|
||||
if [[ "$REPOSITORY" = "openstack-manuals" && "$DOCNAME" = "common-rst" ]] ; then
|
||||
DIRECTORY="doc/common-rst-work"
|
||||
# all files under common. To this aim, we create such document called
|
||||
# 'common-work' dynamically to generate the POT file of common.
|
||||
if [[ "$REPOSITORY" = "openstack-manuals" && "$DOCNAME" = "common" ]] ; then
|
||||
DIRECTORY="doc/common-work"
|
||||
TOPDIR="doc/"
|
||||
mkdir -p $DIRECTORY/source
|
||||
cp doc/common-rst/source/conf.py $DIRECTORY/source/conf.py
|
||||
ln -sf ../../common-rst $DIRECTORY/source/common
|
||||
cp doc/common/source/conf.py $DIRECTORY/source/conf.py
|
||||
ln -sf ../../common $DIRECTORY/source/common
|
||||
cat <<EOF > $DIRECTORY/source/index.rst
|
||||
.. toctree::
|
||||
:maxdepth: 2
|
||||
@ -56,7 +56,7 @@ fi
|
||||
|
||||
if [ "$REPOSITORY" = "openstack-manuals" ] ; then
|
||||
# Build Glossary
|
||||
tools/glossary2rst.py doc/common-rst/glossary.rst
|
||||
tools/glossary2rst.py doc/common/glossary.rst
|
||||
fi
|
||||
# First remove the old pot file, otherwise the new file will contain
|
||||
# old references
|
||||
@ -74,16 +74,16 @@ fi
|
||||
sphinx-build -j $NUMBER_OF_CORES -b gettext $TAG ${DIRECTORY}/source/ \
|
||||
${DIRECTORY}/source/locale/
|
||||
|
||||
if [[ "$REPOSITORY" = "openstack-manuals" && "$DOCNAME" = "common-rst" ]] ; then
|
||||
# In case of common-rst, we use the working directory 'common-rst-work'.
|
||||
# Copies the generated POT to common-rst/source/locale
|
||||
if [[ "$REPOSITORY" = "openstack-manuals" && "$DOCNAME" = "common" ]] ; then
|
||||
# In case of common, we use the working directory 'common-work'.
|
||||
# Copies the generated POT to common/source/locale
|
||||
# and finally removes the working directory.
|
||||
msgcat ${DIRECTORY}/source/locale/common.pot | \
|
||||
awk '$0 !~ /^\# [a-z0-9]+$/' \
|
||||
> ${TOPDIR}common-rst/source/locale/common-rst.pot
|
||||
> ${TOPDIR}common/source/locale/common.pot
|
||||
rm -rf $DIRECTORY
|
||||
else
|
||||
# common-rst is translated as part of openstack-manuals, do not
|
||||
# common is translated as part of openstack-manuals, do not
|
||||
# include the file in the combined tree if it exists.
|
||||
rm -f ${DIRECTORY}/source/locale/common.pot
|
||||
# Take care of deleting all temporary files so that
|
||||
|
@ -26,7 +26,7 @@ function copy_rst_trans {
|
||||
for lang in ja ; do
|
||||
TARGET=$PROJECT_DIR/$target/source/locale/$lang/LC_MESSAGES
|
||||
mkdir -p $TARGET
|
||||
cp doc/common-rst/source/locale/$lang/LC_MESSAGES/common-rst.po \
|
||||
cp doc/common/source/locale/$lang/LC_MESSAGES/common.po \
|
||||
$TARGET
|
||||
done
|
||||
(cd $PROJECT_DIR; git add $target/source/locale/)
|
||||
@ -39,7 +39,7 @@ function copy_rst {
|
||||
tools/glossary2rst.py $PROJECT_DIR/$target/glossary.rst
|
||||
|
||||
for filename in app_support.rst conventions.rst; do
|
||||
cp doc/common-rst/$filename $PROJECT_DIR/$target
|
||||
cp doc/common/$filename $PROJECT_DIR/$target
|
||||
done
|
||||
(cd $PROJECT_DIR; git add $target)
|
||||
}
|
||||
|
8
tox.ini
@ -90,7 +90,7 @@ commands =
|
||||
sitepackages=True
|
||||
whitelist_externals = doc-tools-check-languages
|
||||
commands =
|
||||
{toxinidir}/tools/glossary2rst.py doc/common-rst/glossary.rst
|
||||
{toxinidir}/tools/glossary2rst.py doc/common/glossary.rst
|
||||
doc-tools-check-languages doc-tools-check-languages.conf test all
|
||||
|
||||
[testenv:buildlang]
|
||||
@ -101,7 +101,7 @@ commands =
|
||||
sitepackages=True
|
||||
whitelist_externals = doc-tools-check-languages
|
||||
commands =
|
||||
{toxinidir}/tools/glossary2rst.py doc/common-rst/glossary.rst
|
||||
{toxinidir}/tools/glossary2rst.py doc/common/glossary.rst
|
||||
doc-tools-check-languages doc-tools-check-languages.conf test {posargs}
|
||||
|
||||
[testenv:publishlang]
|
||||
@ -111,7 +111,7 @@ commands =
|
||||
sitepackages=True
|
||||
whitelist_externals = doc-tools-check-languages
|
||||
commands =
|
||||
{toxinidir}/tools/glossary2rst.py doc/common-rst/glossary.rst
|
||||
{toxinidir}/tools/glossary2rst.py doc/common/glossary.rst
|
||||
doc-tools-check-languages doc-tools-check-languages.conf publish all
|
||||
|
||||
[testenv:generatepot-rst]
|
||||
@ -123,7 +123,7 @@ commands = {toxinidir}/tools/generatepot-rst.sh openstack-manuals 1 {posargs}
|
||||
# Settings for doc8:
|
||||
# Ignore target directories
|
||||
# TODO(samos123): remove sriov from ignore when fix for #1487302 is in doc8
|
||||
ignore-path = doc/*/target,doc/*/build*,doc/common-rst/glossary.rst,doc/networking-guide/source/adv-config-sriov.rst
|
||||
ignore-path = doc/*/target,doc/*/build*,doc/common/glossary.rst,doc/networking-guide/source/adv-config-sriov.rst
|
||||
# File extensions to use
|
||||
extensions = .rst,.txt
|
||||
# Maximal line length should be 79 but we have some overlong lines.
|
||||
|