-
Notifications
You must be signed in to change notification settings - Fork 1
94 lines (81 loc) · 2.41 KB
/
Copy pathrelease.yml
File metadata and controls
94 lines (81 loc) · 2.41 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
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
89
90
91
92
93
94
name: release
on:
push:
tags:
- "v*"
workflow_dispatch:
inputs:
tag:
description: "Tag to release (e.g. v0.1.0)"
required: true
permissions:
contents: write
jobs:
build:
strategy:
fail-fast: false
matrix:
include:
- os: macos-latest
bun-target: bun-darwin-arm64
triple: aarch64-apple-darwin
- os: macos-13
bun-target: bun-darwin-x64
triple: x86_64-apple-darwin
- os: ubuntu-latest
bun-target: bun-linux-x64
triple: x86_64-unknown-linux-gnu
- os: ubuntu-24.04-arm
bun-target: bun-linux-arm64
triple: aarch64-unknown-linux-gnu
- os: windows-latest
bun-target: bun-windows-x64
triple: x86_64-pc-windows-msvc
experimental: true
runs-on: ${{ matrix.os }}
continue-on-error: ${{ matrix.experimental == true }}
steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- name: Install deps
run: bun install --frozen-lockfile
- name: Build binary
shell: bash
env:
BUN_TARGET: ${{ matrix.bun-target }}
run: bun run scripts/build-binaries.ts "$BUN_TARGET"
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: quoteforge-${{ matrix.triple }}
path: |
dist/quoteforge-${{ matrix.triple }}.tar.gz
dist/quoteforge-${{ matrix.triple }}.tar.gz.sha256
dist/quoteforge-${{ matrix.triple }}.zip
dist/quoteforge-${{ matrix.triple }}.zip.sha256
if-no-files-found: ignore
release:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Download all artifacts
uses: actions/download-artifact@v4
with:
path: dist
merge-multiple: true
- name: List artifacts
run: ls -la dist/
- name: Publish release
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ github.event.inputs.tag || github.ref_name }}
files: |
dist/quoteforge-*.tar.gz
dist/quoteforge-*.tar.gz.sha256
dist/quoteforge-*.zip
dist/quoteforge-*.zip.sha256
generate_release_notes: true
fail_on_unmatched_files: false