mirror of
https://github.com/fluencelabs/wasmer
synced 2024-12-13 06:15:33 +00:00
Improve CircleCI releases
This commit is contained in:
parent
3dc911989f
commit
21c74db3df
@ -42,8 +42,11 @@ jobs:
|
|||||||
keys:
|
keys:
|
||||||
- v4-cargo-cache-linux-{{ arch }}-{{ checksum "Cargo.lock" }}
|
- v4-cargo-cache-linux-{{ arch }}-{{ checksum "Cargo.lock" }}
|
||||||
- run: sudo apt-get install -y cmake
|
- run: sudo apt-get install -y cmake
|
||||||
- run: make test
|
|
||||||
- run:
|
- run:
|
||||||
|
name: Execute tests
|
||||||
|
command: make test
|
||||||
|
- run:
|
||||||
|
name: Make release build
|
||||||
command: |
|
command: |
|
||||||
make release
|
make release
|
||||||
mkdir -p artifacts
|
mkdir -p artifacts
|
||||||
@ -99,7 +102,7 @@ jobs:
|
|||||||
export PATH="$HOME/.cargo/bin:$PATH"
|
export PATH="$HOME/.cargo/bin:$PATH"
|
||||||
make test
|
make test
|
||||||
- run:
|
- run:
|
||||||
name: Make build
|
name: Make release build
|
||||||
command: |
|
command: |
|
||||||
export PATH="`pwd`/cmake-3.4.1-Darwin-x86_64/CMake.app/Contents/bin:$PATH"
|
export PATH="`pwd`/cmake-3.4.1-Darwin-x86_64/CMake.app/Contents/bin:$PATH"
|
||||||
export PATH="$HOME/.cargo/bin:$PATH"
|
export PATH="$HOME/.cargo/bin:$PATH"
|
||||||
@ -134,11 +137,17 @@ jobs:
|
|||||||
command: |
|
command: |
|
||||||
# go get github.com/tcnksm/ghr
|
# go get github.com/tcnksm/ghr
|
||||||
# VERSION=$(git log -1 --pretty=%B)
|
# VERSION=$(git log -1 --pretty=%B)
|
||||||
|
# VERSION=$(./artifacts/ --version)
|
||||||
VERSION=$(cat ./artifacts/version)
|
VERSION=$(cat ./artifacts/version)
|
||||||
rm ./artifacts/version
|
rm ./artifacts/version
|
||||||
# VERSION=${CIRCLE_TAG}
|
VERSION_TAG=${CIRCLE_TAG}
|
||||||
# VERSION=$(./artifacts/ --version)
|
if [ "$VERSION" == "$VERSION_TAG" ]; then
|
||||||
ghr -t ${GITHUB_TOKEN} -u ${CIRCLE_PROJECT_USERNAME} -r ${CIRCLE_PROJECT_REPONAME} -c ${CIRCLE_SHA1} -delete ${VERSION} ./artifacts/
|
echo "Versions match, publishing to Github"
|
||||||
|
ghr -t ${GITHUB_TOKEN} -u ${CIRCLE_PROJECT_USERNAME} -r ${CIRCLE_PROJECT_REPONAME} -c ${CIRCLE_SHA1} -delete ${VERSION} ./artifacts/
|
||||||
|
else
|
||||||
|
echo "Versions don't match. Wasmer output version (wasmer --version) is ${VERSION} while Git tag is ${VERSION_TAG}"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
workflows:
|
workflows:
|
||||||
version: 2
|
version: 2
|
||||||
@ -165,8 +174,8 @@ workflows:
|
|||||||
requires:
|
requires:
|
||||||
- test-and-build
|
- test-and-build
|
||||||
- test-and-build-macos
|
- test-and-build-macos
|
||||||
# filters:
|
filters:
|
||||||
# branches:
|
branches:
|
||||||
# ignore: /.*/
|
ignore: /.*/
|
||||||
# tags:
|
tags:
|
||||||
# only: /^\d+\.\d+\.\d+$/
|
only: /^\d+\.\d+\.\d+$/
|
||||||
|
Loading…
Reference in New Issue
Block a user