From 0558c585978c1d37aa74436bb09f4d5d4c2c1aad Mon Sep 17 00:00:00 2001 From: Aric Gardner Date: Thu, 4 Feb 2016 14:48:26 -0500 Subject: Need to have reviews under /$PROJECT/$review_number If all the reviews are just review/$review_number I dont have sufficent information to search reviews per project this is needed for the new search tool If this change is merged I will need to delete everything under /review/ this will lose current review artifacts, but allow future ones to be searchable in the upcomming interface Please comment if you can think of a better way to do this. note: at some past point reviews were in their project folder. Change-Id: I0778ca92a0a0922c6e5f2749edd0c9f6a2dcc591 Signed-off-by: Aric Gardner --- jjb/releng-macros.yaml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'jjb') diff --git a/jjb/releng-macros.yaml b/jjb/releng-macros.yaml index 5d9570705..b43a76d5f 100644 --- a/jjb/releng-macros.yaml +++ b/jjb/releng-macros.yaml @@ -195,7 +195,7 @@ echo "###########################" echo - gs_base="artifacts.opnfv.org/review" + gs_base="artifacts.opnfv.org/$PROJECT/review" gs_path="$gs_base/$GERRIT_CHANGE_NUMBER" local_path="upload/$GERRIT_CHANGE_NUMBER" @@ -283,6 +283,13 @@ [[ $GERRIT_CHANGE_NUMBER =~ .+ ]] + gs_path="artifacts.opnfv.org/$PROJECT/review/$GERRIT_CHANGE_NUMBER" + + if gsutil ls "gs://$gs_path" > /dev/null 2>&1 ; then + echo + echo "Deleting Out-of-dated Documents..." + gsutil -m rm -r "gs://$gs_path" + fi gs_path="artifacts.opnfv.org/review/$GERRIT_CHANGE_NUMBER" if gsutil ls "gs://$gs_path" > /dev/null 2>&1 ; then -- cgit 1.2.3-korg