2016-04-04 11:35:32 -05:00
|
|
|
#!/bin/bash
|
|
|
|
|
2016-04-30 03:02:43 -05:00
|
|
|
declare -a upstreams
|
2019-10-15 07:37:04 -05:00
|
|
|
upstreams=(opm-common
|
2018-01-17 04:56:42 -06:00
|
|
|
opm-grid)
|
2016-04-30 03:02:43 -05:00
|
|
|
|
|
|
|
declare -A upstreamRev
|
2018-03-05 06:05:46 -06:00
|
|
|
upstreamRev[opm-common]=master
|
2016-04-30 03:02:43 -05:00
|
|
|
upstreamRev[opm-grid]=master
|
|
|
|
|
2016-08-23 07:30:13 -05:00
|
|
|
if grep -q "opm-common=" <<< $ghprbCommentBody
|
|
|
|
then
|
|
|
|
upstreamRev[opm-common]=pull/`echo $ghprbCommentBody | sed -r 's/.*opm-common=([0-9]+).*/\1/g'`/merge
|
|
|
|
fi
|
|
|
|
|
|
|
|
# Currently no downstreams
|
|
|
|
declare -a downstreams
|
|
|
|
declare -A downstreamRev
|
2016-04-04 11:35:32 -05:00
|
|
|
|
2016-08-23 07:30:13 -05:00
|
|
|
# Clone opm-common
|
|
|
|
pushd .
|
|
|
|
mkdir -p $WORKSPACE/deps/opm-common
|
|
|
|
cd $WORKSPACE/deps/opm-common
|
|
|
|
git init .
|
|
|
|
git remote add origin https://github.com/OPM/opm-common
|
|
|
|
git fetch --depth 1 origin ${upstreamRev[opm-common]}:branch_to_build
|
2016-04-04 11:35:32 -05:00
|
|
|
test $? -eq 0 || exit 1
|
2016-08-23 07:30:13 -05:00
|
|
|
git checkout branch_to_build
|
|
|
|
popd
|
|
|
|
|
|
|
|
source $WORKSPACE/deps/opm-common/jenkins/build-opm-module.sh
|
|
|
|
|
|
|
|
parseRevisions
|
|
|
|
printHeader opm-upscaling
|
|
|
|
|
|
|
|
# Setup opm-data
|
2018-04-03 05:39:25 -05:00
|
|
|
source $WORKSPACE/deps/opm-common/jenkins/setup-opm-tests.sh
|
2016-04-04 11:35:32 -05:00
|
|
|
|
2016-08-23 07:30:13 -05:00
|
|
|
build_module_full opm-upscaling
|