Skip to content

Commit f348a66

Browse files
authored
Merge pull request #21 from itowlson/ci
Release workflow
2 parents b7853ad + feb25ea commit f348a66

File tree

1 file changed

+45
-0
lines changed

1 file changed

+45
-0
lines changed

.github/workflows/release.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json
2+
name: Release
3+
4+
on:
5+
push:
6+
tags:
7+
- "v*"
8+
9+
jobs:
10+
assets:
11+
name: Build and release assets
12+
runs-on: "ubuntu-latest"
13+
steps:
14+
- uses: actions/checkout@v2
15+
16+
- name: set the release version (tag)
17+
run: echo "RELEASE_VERSION=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_ENV
18+
19+
- name: Install latest Rust stable toolchain
20+
uses: actions-rs/toolchain@v1
21+
with:
22+
toolchain: stable
23+
default: true
24+
components: clippy, rustfmt
25+
26+
- name: Install Wasm Rust target
27+
run: rustup target add wasm32-wasi
28+
29+
- name: Make
30+
run: make
31+
env:
32+
RUST_LOG: spin=trace
33+
34+
- name: generate checksums
35+
run: |
36+
sha256sum target/wasm32-wasi/release/spin_static_fs.wasm > checksums-${{ env.RELEASE_VERSION }}.txt
37+
38+
- name: Create release
39+
uses: softprops/action-gh-release@v1
40+
with:
41+
fail_on_unmatched_files: true
42+
generate_release_notes: true
43+
files: |
44+
target/wasm32-wasi/release/spin_static_fs.wasm
45+
checksums-${{ env.RELEASE_VERSION }}.txt

0 commit comments

Comments
 (0)