summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAric Gardner <agardner@linuxfoundation.org>2015-09-01 11:11:32 -0400
committerAric Gardner <agardner@linuxfoundation.org>2015-09-01 11:11:32 -0400
commit9e5b6238fbc2de54cdc465957fc02776567c4418 (patch)
tree906f130a4aa0c69301048414019a7715564adf6f
parent5e9be094411269cbf0198816f514c8a6e2e994e9 (diff)
Move some variables, remove trailing slash from gsutil upload
Change-Id: I15e6ab382eadf45316272b87cf90e564784f7714 Signed-off-by: Aric Gardner <agardner@linuxfoundation.org>
-rwxr-xr-xjjb/releng/docu-build-new.sh15
1 files changed, 9 insertions, 6 deletions
diff --git a/jjb/releng/docu-build-new.sh b/jjb/releng/docu-build-new.sh
index b4d58f3da..21c374615 100755
--- a/jjb/releng/docu-build-new.sh
+++ b/jjb/releng/docu-build-new.sh
@@ -40,14 +40,22 @@ for dir in "${{directories[@]}}"; do
fi
sphinx-build -b html -E -c docs/etc/ ""$dir"/" docs/output/"${{dir##*/}}/"
+
done
# NOTE: make sure source parameters for GS paths are not empty.
[[ $GERRIT_CHANGE_NUMBER =~ .+ ]]
[[ $GERRIT_PROJECT =~ .+ ]]
[[ $GERRIT_BRANCH =~ .+ ]]
+
gs_path_review="artifacts.opnfv.org/review/$GERRIT_CHANGE_NUMBER"
+if [[ $GERRIT_BRANCH = "master" ]] ; then
+ gs_path_branch="artifacts.opnfv.org/$GERRIT_PROJECT"
+else
+ gs_path_branch="artifacts.opnfv.org/$GERRIT_PROJECT/${{GERRIT_BRANCH##*/}}"
+fi
+
for dir in "${{directories[@]}}"; do
echo
echo "#############################"
@@ -55,11 +63,6 @@ for dir in "${{directories[@]}}"; do
echo "#############################"
echo
- if [[ $GERRIT_BRANCH = "master" ]] ; then
- gs_path_branch="artifacts.opnfv.org/$GERRIT_PROJECT"
- else
- gs_path_branch="artifacts.opnfv.org/$GERRIT_PROJECT/${{GERRIT_BRANCH##*/}}"
- fi
if [[ $JOB_NAME =~ "verify" ]] ; then
@@ -83,7 +86,7 @@ for dir in "${{directories[@]}}"; do
else
#upload artifacts for merge job
- gsutil cp -r docs/output/"${{dir##*/}}/" "gs://$gs_path_branch/"${{dir}}/""
+ gsutil cp -r docs/output/"${{dir##*/}}" "gs://$gs_path_branch/"${{dir}}/""
echo "Latest document is available at http://$gs_path_branch/"${{dir}}/"index.html"
#set cache to 0