Add action dialog #3
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Swift | |
on: | |
push: | |
branches: ["main"] | |
pull_request: | |
branches: ["main"] | |
env: | |
PACKAGE: SwiftUIElements | |
jobs: | |
macos: | |
runs-on: macos-13 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Setup Xcode 15 | |
uses: maxim-lobanov/setup-xcode@v1 | |
with: | |
xcode-version: 15 | |
- name: Build (macOS) | |
run: swift build -v --package-path . | |
- name: Test (macOS) | |
run: swift test -v --package-path . | |
ios: | |
runs-on: macos-13 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Setup Xcode 15 | |
uses: maxim-lobanov/setup-xcode@v1 | |
with: | |
xcode-version: 15 | |
- name: Build (iOS) | |
run: xcodebuild build -scheme $PACKAGE -sdk iphoneos -destination 'generic/platform=iOS,name=iPhone 15' | |
- name: Test (iOS) | |
run: xcodebuild test -scheme $PACKAGE -sdk iphonesimulator -destination 'platform=iOS Simulator,name=iPhone 15' | |
# ios: | |
# runs-on: macos-13 | |
# strategy: | |
# matrix: | |
# include: | |
# # - ios-version: '13.0' | |
# # device: 'iPhone 11' | |
# # - ios-version: '15.0' | |
# # device: 'iPhone 13' | |
# - ios-version: '17.0' | |
# device: 'iPhone 15' | |
# steps: | |
# - uses: actions/checkout@v3 | |
# - name: Setup Xcode 15 | |
# uses: maxim-lobanov/setup-xcode@v1 | |
# with: | |
# xcode-version: 15 | |
# - name: Build (iOS) | |
# run: xcodebuild build -scheme $PACKAGE -sdk iphoneos -destination 'generic/platform=iOS,OS=${{ matrix.ios-version }},Name=${{ matrix.device }}' | |
# - name: Test (iOS) | |
# run: xcodebuild test -scheme $PACKAGE -sdk iphoneos -destination 'platform=iOS Simulator,OS=${{ matrix.ios-version }},Name=${{ matrix.device }}' | |
# tvos: | |
# runs-on: macos-13 | |
# steps: | |
# - uses: actions/checkout@v3 | |
# - name: Setup Xcode 15 | |
# uses: maxim-lobanov/setup-xcode@v1 | |
# with: | |
# xcode-version: 15 | |
# - name: Build (tvOS) | |
# run: xcodebuild build -scheme $PACKAGE -sdk appletvos -destination 'generic/platform=tvOS' | |
# - name: Test (tvOS) | |
# run: xcodebuild test -scheme $PACKAGE -sdk appletvos -destination 'platform=tvOS Simulator,name=Apple TV' | |
# watchos: | |
# runs-on: macos-13 | |
# steps: | |
# - uses: actions/checkout@v3 | |
# - name: Setup Xcode 15 | |
# uses: maxim-lobanov/setup-xcode@v1 | |
# with: | |
# xcode-version: 15 | |
# - name: Build (watchOS) | |
# run: xcodebuild build -scheme $PACKAGE -sdk watchos -destination 'generic/platform=watchOS' | |
# # Tests are not supported on watchOS |