Really skip directories for translation sync

This fixes a problem on stable/liberty for openstack-manuals where only
2 out of 12 directories should be translated. But we currently push all
12 source files to the server.

If we have directories that contain locale files, we need to explicitly
exclude them. Add the skip directories to the exclude list for
manual projects.

Change-Id: I1eb481772545261c293baa0eb35731a8ac92d53c
This commit is contained in:
Andreas Jaeger 2015-11-23 09:06:36 +01:00
parent 61ff25ede0
commit d69c742245

View File

@ -67,6 +67,13 @@ function setup_manuals {
# Grab all of the rules for the documents we care about
ZANATA_RULES=
# List of directories to skip
if [ "$project" == "openstack-manuals" ]; then
EXCLUDE='.*/**,**/source/common/**'
else
EXCLUDE='.*/**,**/source/common/**,**/glossary/**'
fi
# Generate pot one by one
for FILE in ${DocFolder}/*; do
# Skip non-directories
@ -89,6 +96,7 @@ function setup_manuals {
IS_RST=1
;;
skip)
EXCLUDE="$EXCLUDE,${DocFolder}/${DOCNAME}/**"
continue
;;
esac
@ -107,11 +115,6 @@ function setup_manuals {
fi
fi
done
if [ "$project" == "openstack-manuals" ]; then
EXCLUDE='.*/**,**/source/common/**'
else
EXCLUDE='.*/**,**/source/common/**,**/glossary/**'
fi
/usr/local/jenkins/slave_scripts/create-zanata-xml.py -p $project \
-v $version --srcdir . --txdir . $ZANATA_RULES -e "$EXCLUDE" \
-f zanata.xml