-
Notifications
You must be signed in to change notification settings - Fork 16
63 lines (61 loc) · 1.58 KB
/
main.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
name: CI
on:
push:
branches: [ master ]
tags: [ 'v*' ]
pull_request:
branches: [ master ]
jobs:
build-mingw:
name: Build (MinGW)
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@v11
- uses: DeterminateSystems/magic-nix-cache-action@v6
- uses: DeterminateSystems/flake-checker-action@v7
- name: Check formatting
continue-on-error: true
run: |
shopt -s globstar
nix develop --command clang-format --dry-run -Werror src/**/*.c src/**/*.h
- name: Build + Test
run: nix build
- name: Upload
uses: actions/upload-artifact@v4
with:
name: ijl15.dll
path: result/lib/ijl15.dll
build-msvc:
name: Build (MSVC)
runs-on: windows-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- uses: ilammy/msvc-dev-cmd@v1
- name: Build
run: msbuild.exe rugburn.sln "/p:Configuration=Release;Platform=x86"
- name: Upload
uses: actions/upload-artifact@v4
with:
name: ijl15-msvc.dll
path: out/Win32/Release/ijl15.dll
release:
name: Release
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/')
needs: build-mingw
steps:
- name: Download builds
uses: actions/download-artifact@v4
with:
name: ijl15.dll
- name: Create Release
uses: softprops/action-gh-release@v2
with:
draft: true
generate_release_notes: true
fail_on_unmatched_files: true
files:
ijl15.dll