File tree Expand file tree Collapse file tree 2 files changed +22
-10
lines changed Expand file tree Collapse file tree 2 files changed +22
-10
lines changed Original file line number Diff line number Diff line change 1- name : release binaries
1+ name : Build/Release binaries
22
33on :
44 release :
55 types : [published]
6+ pull_request :
7+ branches :
8+ - " *"
9+ push :
10+ branches :
11+ - " *"
612
713env :
814 CARGO_TERM_COLOR : always
915
1016jobs :
1117 build :
12-
1318 runs-on : ubuntu-latest
14-
1519 steps :
1620 - uses : actions/checkout@v2
1721 - name : Toolchain installation
1822 run : sh -c "rustup toolchain install nightly && rustup target add wasm32-unknown-unknown && cargo install wasm-pack"
1923
2024 - name : Build binaries
2125 run : sh release-binaries.sh
22-
23- - uses : actions/upload-artifact@v2
24- with :
25- name : wasm-filters.tar.gz
26- path : ./wasm-filters.tar.gz
26+
27+ # the below step will take place only when there is a release
28+ - name : Upload wasm binaries to the latest made release
29+ if : github.event_name == 'release'
30+ run : |
31+ set -x
32+ assets=()
33+ for asset in ./wasm-filters/*.wasm; do
34+ assets+=("-a" "$asset")
35+ done
36+ tag_name="${GITHUB_REF##*/}"
37+ hub release edit "${assets[@]}" -m "" "$tag_name"
38+ env :
39+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
2740
2841
Original file line number Diff line number Diff line change @@ -28,7 +28,6 @@ for d in */ ; do
2828fi
2929cd ..
3030done
31- cd wasm-filters
32- tar -czvf wasm-filters.tar.gz ./wasm-filters
31+
3332
3433
You can’t perform that action at this time.
0 commit comments