summaryrefslogtreecommitdiffstats
path: root/integration/src/main/scripts/release/updateRefs.sh
diff options
context:
space:
mode:
authorliamfallon <liam.fallon@est.tech>2022-07-13 11:40:56 +0100
committerliamfallon <liam.fallon@est.tech>2022-07-13 12:59:13 +0100
commit555565323a6095abcbe1a761faac2d71a455dfe0 (patch)
tree527aab3c52dad31444bbefc408af67168455aa10 /integration/src/main/scripts/release/updateRefs.sh
parent12fea027b14c36fe3b8e16f5a2aeedab8366285c (diff)
Update release and report scripts
Release scripts are updated to automatically change the releae data CSV file in policy-parent/integration/src/main/resources Report script is updated t add HTTP links to the various reports Issue-ID: POLICY-4233 Change-Id: Id98a4e2805caf68a66dd5844f388c045f75a8865 Signed-off-by: liamfallon <liam.fallon@est.tech>
Diffstat (limited to 'integration/src/main/scripts/release/updateRefs.sh')
-rwxr-xr-xintegration/src/main/scripts/release/updateRefs.sh20
1 files changed, 19 insertions, 1 deletions
diff --git a/integration/src/main/scripts/release/updateRefs.sh b/integration/src/main/scripts/release/updateRefs.sh
index 0f253f97..14f90d9a 100755
--- a/integration/src/main/scripts/release/updateRefs.sh
+++ b/integration/src/main/scripts/release/updateRefs.sh
@@ -54,6 +54,7 @@ usage()
echo " -o - update policy/drools-pdp references"
echo " -x - update policy/apex-pdp references"
echo " -k - update docker base images in Dockerfiles"
+ echo " -f - update release data in policy parent"
echo " -s - update release references to snapshot references,"
echo " if omitted, snapshot references are updated to release references"
echo ""
@@ -75,8 +76,9 @@ update_drools_pdp=false
update_apex_pdp=false
update_snapshot=false
update_docker=false
+update_file=false
-while getopts "hd:l:r:pcmoxks" opt
+while getopts "hd:l:r:pcmoxkfs" opt
do
case $opt in
h)
@@ -109,6 +111,9 @@ do
k)
update_docker=true
;;
+ f)
+ update_file=true
+ ;;
s)
update_snapshot=true
;;
@@ -411,3 +416,16 @@ then
exit 1
fi
fi
+
+if [ "$update_file" = true ]
+then
+ if [ ! "$target_repo" = "policy/parent" ]
+ then
+ echo "update of data file can only be done on the policy/parent repo"
+ exit 1
+ fi
+
+ echo "updating release data at $repo_location/$target_repo/integration/src/main/resources/release . . ."
+ cp "$release_data_file" "$repo_location/$target_repo"/integration/src/main/resources/release
+ echo "updated release data at $repo_location/$target_repo/integration/src/main/resources/release"
+fi