diff options
author | Damien Martin-Guillerez <dmarting@google.com> | 2017-01-20 09:48:55 +0000 |
---|---|---|
committer | Vladimir Moskva <vladmos@google.com> | 2017-01-20 12:21:13 +0000 |
commit | 0496b2a323b3570cbc90a5f67b40d65d2df4a5c9 (patch) | |
tree | 5b0baa5bc776d8b8500b6b242e222e007ad586fd /scripts/bootstrap | |
parent | 5a7ea196fafa9ce19486a64054e1b55e5c9e19b0 (diff) |
Use regex to match error prone and guava jar
Hard-coding the version is causing difficulties to update error prone, so let's not do it.
--
PiperOrigin-RevId: 145061484
MOS_MIGRATED_REVID=145061484
Diffstat (limited to 'scripts/bootstrap')
-rwxr-xr-x | scripts/bootstrap/compile.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/bootstrap/compile.sh b/scripts/bootstrap/compile.sh index 8508682d23..a909c09a29 100755 --- a/scripts/bootstrap/compile.sh +++ b/scripts/bootstrap/compile.sh @@ -30,8 +30,8 @@ LIBRARY_JARS="${LIBRARY_JARS} ${GRPC_LIBRARY_JARS}" LIBRARY_JARS_ARRAY=($LIBRARY_JARS) for i in $(seq 0 $((${#LIBRARY_JARS_ARRAY[@]} - 1))) do - [ "${LIBRARY_JARS_ARRAY[$i]}" = "third_party/error_prone/error_prone_core-2.0.13.jar" ] && ERROR_PRONE_INDEX=$i - [ "${LIBRARY_JARS_ARRAY[$i]}" = "third_party/guava/guava-21.0-20161101.jar" ] && GUAVA_INDEX=$i + [[ "${LIBRARY_JARS_ARRAY[$i]}" =~ ^"third_party/error_prone/error_prone_core-".*\.jar$ ] && ERROR_PRONE_INDEX=$i + [[ "${LIBRARY_JARS_ARRAY[$i]}" =~ ^"third_party/guava/guava-".*\.jar$ ] && GUAVA_INDEX=$i done [ "${ERROR_PRONE_INDEX:+present}" = "present" ] || { echo "no error prone jar"; echo "${LIBRARY_JARS_ARRAY[@]}"; exit 1; } [ "${GUAVA_INDEX:+present}" = "present" ] || { echo "no guava jar"; exit 1; } |