-
Notifications
You must be signed in to change notification settings - Fork 0
40 lines (34 loc) · 1.66 KB
/
xcodebuild.yml
File metadata and controls
40 lines (34 loc) · 1.66 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
# This workflow will build a Swift project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-swift
name: Swift
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
runs-on: macos-26
steps:
- uses: actions/checkout@v4
- name: Install SwiftLint
run: brew install swiftlint
- name: Lint
run: swiftlint lint --config .swiftlint.yml
# iOS build (default)
- name: Build iOS
run: xcodebuild -scheme OAuthSample -configuration Debug CODE_SIGNING_ALLOWED=NO -destination "generic/platform=iOS"
# macOS build (if the PR has the label of 'os:macOS' applied)
- name: Build macOS
if: ${{ contains(github.event.pull_request.labels.*.name, 'macOS') }}
run: xcodebuild -scheme OAuthSample -configuration Debug CODE_SIGNING_ALLOWED=NO -destination "generic/platform=macOS"
# visionOS build (if the PR has the label of 'os:visionOS' applied)
- name: Build visionOS
if: ${{ contains(github.event.pull_request.labels.*.name, 'visionOS') }}
run: xcodebuild -scheme OAuthSample -configuration Debug CODE_SIGNING_ALLOWED=NO -destination "generic/platform=visionOS"
- name: Build tvOS
if: ${{ contains(github.event.pull_request.labels.*.name, 'tvOS') }}
run: xcodebuild -scheme OAuthSample -configuration Debug CODE_SIGNING_ALLOWED=NO -destination "generic/platform=tvOS"
- name: Build watchOS
if: ${{ contains(github.event.pull_request.labels.*.name, 'watchOS') }}
run: xcodebuild -scheme OAuthSampleWatch -configuration Debug CODE_SIGNING_ALLOWED=NO -destination "generic/platform=watchOS"