-
Notifications
You must be signed in to change notification settings - Fork 34
90 lines (76 loc) · 2.33 KB
/
release.yml
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
name: Build new Herbie release
on:
push:
tags:
- 'v*'
jobs:
build:
name: Build
strategy:
matrix: # manual matrix
include:
- os: windows-latest
os-name: windows
arch: x64
- os: ubuntu-20.04 # keep old for glibc compatability
os-name: ubuntu
arch: x64
- os: macos-latest
os-name: macOS-m1
arch: arm64
- os: macos-13
os-name: macOS
arch: x64
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- name: Install Racket
uses: Bogdanp/[email protected]
with:
version: 8.11
architecture: ${{ matrix.arch }}
- name: Install Rust compiler
uses: dtolnay/rust-toolchain@stable
with:
toolchain: stable
- name: build egg-herbie
run: cargo build --release --manifest-path=egg-herbie/Cargo.toml
- name: Create tarball
run: raco pkg create --format zip egg-herbie
- name: Rename tarballs
run: |
mv egg-herbie.zip egg-herbie-${{ matrix.os-name }}.zip
mv egg-herbie.zip.CHECKSUM egg-herbie-${{ matrix.os-name }}.zip.CHECKSUM
- name: Upload pre-built egg-herbie
uses: actions/upload-artifact@v4
with:
path: egg-herbie-${{ matrix.os-name }}.zip
name: egg-herbie-${{ matrix.os-name }}.zip
if-no-files-found: error
- name: Upload pre-built egg-herbie checksum
uses: actions/upload-artifact@v4
with:
path: egg-herbie-${{ matrix.os-name }}.zip.CHECKSUM
name: egg-herbie-${{ matrix.os-name }}.zip.CHECKSUM
if-no-files-found: error
release:
name: Create Initial Release
runs-on: ubuntu-latest
needs: build
steps:
- name: Download pre-built artifacts
uses: actions/download-artifact@v4
with:
path: artifacts
pattern: egg-herbie-*
merge-multiple: true
- name: Create Release
uses: ncipollo/release-action@v1
with:
tag: ${{ github.ref }}
name: ${{ github.ref }}
commit: ${{ github.commit }}
draft: true
prerelease: false
artifactErrorsFailBuild: true
artifacts: "artifacts/*"