-
Notifications
You must be signed in to change notification settings - Fork 0
88 lines (72 loc) · 2.6 KB
/
release.yaml
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
name: Release
on:
workflow_dispatch:
inputs:
version:
description: "The tag to release to"
required: true
type: string
jobs:
happ:
permissions:
contents: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install nix
uses: cachix/install-nix-action@v30
with:
install_url: https://releases.nixos.org/nix/nix-2.24.10/install
- uses: cachix/cachix-action@v15
with:
name: esl-checked
extraPullNames: holochain-ci
- name: Build happ
env:
GH_TOKEN: ${{ github.token }}
run: |
nix develop --command npm ci
nix develop --command npm run package
cp workdir/checked.happ checked-${{ inputs.version }}.happ
cp workdir/checked.webhapp checked-${{ inputs.version }}.webhapp
gh release upload ${{ inputs.version }} checked-${{ inputs.version }}.happ --clobber
gh release upload ${{ inputs.version }} checked-${{ inputs.version }}.webhapp --clobber
checked_cli:
permissions:
contents: write
strategy:
matrix:
os: [ubuntu-latest, macos-latest, macos-13, windows-latest]
include:
- os: ubuntu-latest
platform: x86_64-linux
- os: macos-latest
platform: aarch64-darwin
- os: macos-13
platform: x86_64-darwin
- os: windows-latest
platform: x86_64-windows
fail-fast: false
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: '^1.21.10'
- uses: Swatinem/rust-cache@v2
- name: Build CLI
if: matrix.os != 'windows-latest'
env:
GH_TOKEN: ${{ github.token }}
run: |
cargo build --release --manifest-path ./checked_cli/Cargo.toml
cp checked_cli/target/release/checked checked-${{ inputs.version }}-${{ matrix.platform }}
gh release upload ${{ inputs.version }} checked-${{ inputs.version }}-${{ matrix.platform }} --clobber
- name: Build CLI for Windows
if: matrix.os == 'windows-latest'
env:
GH_TOKEN: ${{ github.token }}
run: |
cargo build --release --manifest-path ./checked_cli/Cargo.toml
cp checked_cli/target/release/checked.exe checked-${{ inputs.version }}-${{ matrix.platform }}.exe
gh release upload ${{ inputs.version }} checked-${{ inputs.version }}-${{ matrix.platform }}.exe --clobber