-
Notifications
You must be signed in to change notification settings - Fork 0
44 lines (35 loc) · 901 Bytes
/
ci.yml
File metadata and controls
44 lines (35 loc) · 901 Bytes
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
name: CI
on:
push:
branches: [ main, develop ]
pull_request:
branches: [ main ]
jobs:
build-and-test:
runs-on: macos-14
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Swift
uses: swift-actions/setup-swift@v1
with:
swift-version: '5.9'
- name: Cache Swift packages
uses: actions/cache@v3
with:
path: .build
key: ${{ runner.os }}-spm-${{ hashFiles('**/Package.resolved') }}
restore-keys: |
${{ runner.os }}-spm-
- name: Build
run: swift build
- name: Run tests
run: swift test
- name: Build release
run: swift build -c release
- name: Upload build artifacts
uses: actions/upload-artifact@v4
with:
name: Zero-app
path: .build/release/Zero
retention-days: 7