update bazel workspace for emscripten 2.0.3 (#613)
* update bazel workspace for emscripten 2.0.3 * test to make sure WORKSPACE is up to date * make it clear what happened when WORKSPACE is out of date * intentionally add error to make sure circleci fails properly * revert intentionally bad commit * increase visibility of failure message Co-authored-by: Mitch Foley <mitchfoley@google.com>
This commit is contained in:
@@ -5,5 +5,20 @@ echo "test bazel"
|
||||
set -x
|
||||
set -e
|
||||
|
||||
# Get the latest version number from emscripten-releases-tag.txt.
|
||||
VER=$(grep -oP '(?<=latest\": \")([\d\.]+)(?=\")' \
|
||||
emscripten-releases-tags.txt \
|
||||
| sed --expression "s/\./\\\./g")
|
||||
# Based on the latest version number, get the commit hash for that version.
|
||||
HASH=$(grep "${VER}" emscripten-releases-tags.txt \
|
||||
| grep -v latest \
|
||||
| cut -f4 -d\")
|
||||
|
||||
FAILMSG="!!! scripts/update_bazel_toolchain.sh needs to be run !!!"
|
||||
|
||||
# Ensure the WORKSPACE file is up to date with the latest version.
|
||||
grep ${VER} bazel/WORKSPACE || (echo ${FAILMSG} && false)
|
||||
grep ${HASH} bazel/WORKSPACE || (echo ${FAILMSG} && false)
|
||||
|
||||
cd bazel
|
||||
bazel build //hello-world:hello-world-wasm
|
||||
|
||||
Reference in New Issue
Block a user