forked from SmartDropLabs/smartdrop-contracts
-
Notifications
You must be signed in to change notification settings - Fork 0
59 lines (48 loc) · 1.48 KB
/
Copy pathrelease.yml
File metadata and controls
59 lines (48 loc) · 1.48 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
name: Release
on:
push:
tags:
- 'v*'
permissions:
contents: write
jobs:
release:
name: Build and publish WASM release
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v7
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@stable
with:
targets: wasm32v1-none
- name: Cache cargo registry and build output
uses: actions/cache@v6
with:
path: |
~/.cargo/registry
~/.cargo/git
soroban/target
key: ${{ runner.os }}-cargo-${{ hashFiles('soroban/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-
- name: Build farming-pool WASM fixture for factory integration tests
working-directory: soroban
run: cargo build -p farming-pool --target wasm32v1-none --release
- name: Run tests
working-directory: soroban
run: cargo test --workspace
- name: Build release WASM
working-directory: soroban
run: cargo build --target wasm32v1-none --release
- name: Generate SHA256 sums
working-directory: soroban
run: |
cd target/wasm32v1-none/release
sha256sum *.wasm > sha256sums.txt
- name: Publish GitHub Release
uses: softprops/action-gh-release@v3
with:
files: |
soroban/target/wasm32v1-none/release/*.wasm
soroban/target/wasm32v1-none/release/sha256sums.txt