forked from apereo/cas
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathanalyze-config-proxying.sh
executable file
·56 lines (41 loc) · 1.7 KB
/
analyze-config-proxying.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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
#!/bin/bash
source ./ci/functions.sh
runBuild=true
gradle="./gradlew $@"
gradleBuild=""
gradleBuildOptions="--build-cache --configure-on-demand --no-daemon "
echo -e "***********************************************"
echo -e "Gradle build started at `date`"
echo -e "***********************************************"
echo "Running dependency analysis..."
gradleBuild="$gradleBuild verifySpringConfigurationCanDisableBeanProxying -x javadoc -x check \
-DskipGradleLint=true --parallel \
-DskipNestedConfigMetadataGen=true "
if [[ "${TRAVIS_COMMIT_MESSAGE}" == *"[show streams]"* ]]; then
gradleBuild="$gradleBuild -DshowStandardStreams=true "
fi
if [[ "${TRAVIS_COMMIT_MESSAGE}" == *"[rerun tasks]"* ]]; then
gradleBuild="$gradleBuild --rerun-tasks "
fi
if [[ "${TRAVIS_COMMIT_MESSAGE}" == *"[refresh dependencies]"* ]]; then
gradleBuild="$gradleBuild --refresh-dependencies "
fi
tasks="$gradle $gradleBuildOptions $gradleBuild"
echo -e "***************************************************************************************"
echo $tasks
echo -e "***************************************************************************************"
waitloop="while sleep 9m; do echo -e '\n=====[ Gradle build is still running ]====='; done &"
eval $waitloop
waitRetVal=$?
eval $tasks
retVal=$?
echo -e "***************************************************************************************"
echo -e "Gradle build finished at `date` with exit code $retVal"
echo -e "***************************************************************************************"
if [ $retVal == 0 ]; then
echo "Gradle build finished successfully."
exit 0
else
echo "Gradle build did NOT finish successfully."
exit $retVal
fi