File tree Expand file tree Collapse file tree 2 files changed +17
-21
lines changed
Expand file tree Collapse file tree 2 files changed +17
-21
lines changed Original file line number Diff line number Diff line change 3939 java-version : 11
4040 distribution : zulu
4141 - name : build
42- run : ./build-coatjava.sh --spotbugs --unittests --quiet
42+ run : ./build-coatjava.sh --spotbugs --unittests --quiet -T4
4343 - name : tar # tarball to preserve permissions
4444 run : tar czvf coatjava.tar.gz coatjava
4545 - uses : actions/upload-artifact@v3
Original file line number Diff line number Diff line change 44set -u
55set -o pipefail
66
7- usage=' build-coatjava.sh [-h] [--quiet] [--spotbugs] [--nomaps] [--unittests]'
7+ usage=' ' ' build-coatjava.sh [-h] [--help] [--quiet] [--spotbugs] [--nomaps] [--unittests]
8+ - all other arguments will be passed to `mvn`, e.g., -T4 will build with 4 parallel threads' ' '
89
910quiet=" no"
1011runSpotBugs=" no"
1112downloadMaps=" yes"
1213runUnitTests=" no"
14+ mvnArgs=()
1315for xx in $@
1416do
15- if [ " $xx " == " --spotbugs" ]
16- then
17- runSpotBugs=" yes"
18- elif [ " $xx " == " -n" ]
19- then
20- runSpotBugs=" no"
21- elif [ " $xx " == " --nomaps" ]
22- then
23- downloadMaps=" no"
24- elif [ " $xx " == " --unittests" ]
25- then
26- runUnitTests=" yes"
27- elif [ " $xx " == " --quiet" ]
28- then
29- quiet=" yes"
30- else
31- echo " $usage "
32- exit 2
33- fi
17+ case $xx in
18+ --spotbugs) runSpotBugs=" yes" ;;
19+ -n) runSpotBugs=" no" ;;
20+ --nomaps) downloadMaps=" no" ;;
21+ --unittests) runUnitTests=" yes" ;;
22+ --quiet) quiet=" yes" ;;
23+ -h|--help)
24+ echo " $usage "
25+ exit 2
26+ ;;
27+ * ) mvnArgs+=($xx ) ;;
28+ esac
3429done
3530
3631top=" $( cd " $( dirname " ${BASH_SOURCE[0]} " ) " & > /dev/null && pwd) "
4237 wget=' wget --progress=dot:mega'
4338 mvn=" mvn -q -B --settings $top /maven-settings.xml"
4439fi
40+ mvn+=" ${mvnArgs[*]} "
4541
4642command_exists () {
4743 type " $1 " & > /dev/null
You can’t perform that action at this time.
0 commit comments