-
Notifications
You must be signed in to change notification settings - Fork 13
57 lines (45 loc) · 1.13 KB
/
macos.yml
File metadata and controls
57 lines (45 loc) · 1.13 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
name: macos
on:
push:
branches: [ 'main' ]
tags:
- '[0-9]+.[0-9]+.[0-9]+'
pull_request:
branches: [ 'main' ]
env:
BUILD_TYPE: Release
jobs:
build:
runs-on: macos-latest
steps:
- name: 'Checkout'
uses: actions/checkout@v4
- name: 'Configure'
run: cmake -B build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DAPP_VERSION="${{github.ref_name}}"
- name: 'Build'
run: cmake --build build --config ${{env.BUILD_TYPE}}
- name: 'Artifact'
uses: actions/upload-artifact@v4
with:
name: 'objcurses-macos'
path: |
build/objcurses
release-to-github:
if: github.ref_type == 'tag'
needs:
- build
runs-on: macos-latest
permissions:
contents: write
steps:
- name: Download all the dists
uses: actions/download-artifact@v4
with:
name: 'objcurses-macos'
path: build/
- name: Zip
run: zip -j -r objcurses-macos-v${{github.ref_name}}.zip ./build/objcurses
- name: Release
uses: softprops/action-gh-release@v2
with:
files: objcurses-macos-v${{github.ref_name}}.zip