forked from rh-openjdk/TestHeadlessComponents
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgenericRunner.sh
executable file
·27 lines (20 loc) · 1.07 KB
/
genericRunner.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/bin/bash
# needs OJDK_VERSION_NUMBER, JRESDK and BOOTJDK_DIR variables set
set -x
set -e
set -o pipefail
## assumes that both directories with old and new rpms are provided and filled with relevant rpms
## this script attempts parallel installation of old and new set of rpms
## resolve folder of this script, following all symlinks,
## http://stackoverflow.com/questions/59895/can-a-bash-script-tell-what-directory-its-stored-in
SCRIPT_SOURCE="${BASH_SOURCE[0]}"
while [ -h "$SCRIPT_SOURCE" ]; do # resolve $SOURCE until the file is no longer a symlink
SCRIPT_DIR="$( cd -P "$( dirname "$SCRIPT_SOURCE" )" && pwd )"
SCRIPT_SOURCE="$(readlink "$SCRIPT_SOURCE")"
# if $SOURCE was a relative symlink, we need to resolve it relative to the path where the symlink file was located
[[ $SCRIPT_SOURCE != /* ]] && SCRIPT_SOURCE="$SCRIPT_DIR/$SCRIPT_SOURCE"
done
readonly SCRIPT_DIR="$( cd -P "$( dirname "$SCRIPT_SOURCE" )" && pwd )"
export RFaT=`bash $SCRIPT_DIR/../get-run-folder-as-tests`
export OJDK_VERSION="ojdk${OJDK_VERSION_NUMBER}"
sh $SCRIPT_DIR/testHeadlessComponents.sh