Swift Package Manager Lint #183
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 Package Manager Lint | |
on: | |
workflow_run: | |
workflows: | |
- 'Build' | |
types: | |
- completed | |
branches: | |
- '**' | |
jobs: | |
spm-lint: | |
name: Lint Package For Swift Package Manager | |
runs-on: macos-13 | |
strategy: | |
matrix: | |
destination: ['generic/platform=iOS Simulator', | |
'generic/platform=iOS', | |
'generic/platform=macOS'] | |
if: ${{ github.event.workflow_run.conclusion == 'success' }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
ref: ${{ github.event.workflow_run.head_branch }} | |
- name: Set Xcode Version | |
uses: maxim-lobanov/setup-xcode@v1 | |
with: | |
xcode-version: '15.0.0' | |
- name: Update Packages | |
run: | | |
swift package update | |
- name: Build Project | |
env: | |
project: ./.github/workflows/SPMDummy/SPMDummy.xcodeproj | |
scheme: SPMDummy | |
destination: ${{ matrix.destination }} | |
run: | | |
xcodebuild clean build -project "${project}" -scheme "${scheme}" -destination "${destination}" CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO | xcpretty && exit ${PIPESTATUS[0]} |