-
-
Notifications
You must be signed in to change notification settings - Fork 7
58 lines (54 loc) · 1.73 KB
/
build.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
name: Build
on: [ push, pull_request ]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build-ubuntu:
strategy:
fail-fast: false
runs-on: ubuntu-22.04
name: Build Ubuntu
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Cache Rust
uses: Swatinem/rust-cache@v2
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install clang libarchive-tools mold
- name: Setup ‘cargo’
uses: actions-rs/toolchain@v1
- name: Configure
run: |
./bootstrap.sh
./configure \
--enable-developer-mode \
--disable-dependency-checks \
CHECKMAKE=false RUFF=false TYPOS=cat
echo "VERSION=$(./build-aux/git-version-gen .tarball-version)" >> $GITHUB_ENV
echo "MAKEFLAGS=-j$(nproc) -Otarget" >> $GITHUB_ENV
- name: Make
run: |
make
- name: Package
run: |
make dist
- name: Upload source dist artifact
if: ${{ ! startsWith(github.ref, 'refs/tags/v') }}
uses: actions/upload-artifact@v4
with:
name: fontship-${{ env.VERSION }}
path: fontship-${{ env.VERSION }}.zip
- name: Release
uses: softprops/action-gh-release@v2
if: github.repository == 'theleagueof/fontship' && startsWith(github.ref, 'refs/tags/v') && contains(github.ref, '.')
with:
body_path: fontship-${{ env.VERSION }}.md
files: |
fontship-${{ env.VERSION }}.zip
fontship-${{ env.VERSION }}.tar.zst
fontship-${{ env.VERSION }}.sha256.txt