-
Notifications
You must be signed in to change notification settings - Fork 0
88 lines (82 loc) · 2.19 KB
/
Copy pathrelease.yml
File metadata and controls
88 lines (82 loc) · 2.19 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
name: Release
on:
push:
tags: ["v*"]
permissions:
contents: write
jobs:
binaries:
name: binary (${{ matrix.os }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-latest
ext: so
- os: macos-latest
ext: dylib
steps:
- uses: actions/checkout@v7
- name: Build loadable extension
run: make loadable
- name: Stage artifact
run: |
mkdir -p out
cp dist/predict0.${{ matrix.ext }} \
out/predict0-${{ runner.os }}-${{ runner.arch }}.${{ matrix.ext }}
- uses: actions/upload-artifact@v7
with:
name: predict0-${{ runner.os }}-${{ runner.arch }}
path: out/*
windows:
name: binary (windows)
runs-on: windows-latest
defaults:
run:
shell: msys2 {0}
steps:
- uses: actions/checkout@v7
- uses: msys2/setup-msys2@v2
with:
msystem: MINGW64
update: true
install: >-
mingw-w64-x86_64-gcc make curl unzip
- name: Build loadable DLL
run: make loadable
- name: Stage artifact
run: |
mkdir -p out
cp dist/predict0.dll out/predict0-Windows-X64.dll
- uses: actions/upload-artifact@v7
with:
name: predict0-Windows-X64
path: out/*
amalgamation:
name: amalgamation
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
# the single-file drop-in build, attached so users can grab one .c file
- name: Generate + compile amalgamation
run: make amalgamation-check
- uses: actions/upload-artifact@v7
with:
name: amalgamation
path: dist/sqlite-predict.c
release:
needs: [binaries, windows, amalgamation]
runs-on: ubuntu-latest
steps:
- uses: actions/download-artifact@v8
with:
path: artifacts
merge-multiple: true
- name: Checksums
run: (cd artifacts && sha256sum * > SHA256SUMS)
- name: Publish release
uses: softprops/action-gh-release@v3
with:
files: artifacts/*
generate_release_notes: true