Merge branch 'deployment-target-macos-14' into deployment-target-maco… #699
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: Build Genius | |
on: | |
push: | |
paths: | |
- .github/workflows/Build-Genius.yml | |
- .periphery.yml | |
- .swift-version | |
- .swiftformat | |
- .swiftlint.yml | |
- Genius/** | |
- Genius.xcodeproj/** | |
- GeniusTests/** | |
pull_request: | |
paths: | |
- .github/workflows/Build-Genius.yml | |
- .periphery.yml | |
- .swift-version | |
- .swiftformat | |
- .swiftlint.yml | |
- Genius/** | |
- Genius.xcodeproj/** | |
- GeniusTests/** | |
workflow_dispatch: | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
env: | |
GH_TOKEN: ${{ github.token }} | |
NSUnbufferedIO: YES | |
jobs: | |
Run-Periphery: | |
name: Run Periphery | |
runs-on: macos-15 | |
steps: | |
- name: Select Xcode Version | |
uses: maxim-lobanov/setup-xcode@master | |
with: | |
xcode-version: latest | |
- name: Checkout | |
uses: actions/checkout@main | |
- name: Install Periphery | |
run: | | |
latest_periphery_tag=$(gh release --repo peripheryapp/periphery list --json tagName --limit 1 | cut -d "\"" -f 4) | |
curl --location https://github.com/peripheryapp/periphery/releases/download/"$latest_periphery_tag"/periphery-"$latest_periphery_tag".zip --output periphery.zip | |
unzip periphery.zip | |
echo "Periphery $(./periphery version) installed" | |
- name: Run Periphery | |
run: ./periphery scan --format github-actions --relative-results --strict -- -skipPackagePluginValidation | |
Run-SwiftFormat: | |
name: Run SwiftFormat | |
runs-on: macos-15 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@main | |
with: | |
fetch-depth: 0 | |
- name: Install SwiftFormat | |
run: | | |
curl --remote-name --location https://github.com/nicklockwood/SwiftFormat/releases/latest/download/swiftformat.zip | |
unzip swiftformat.zip | |
echo "SwiftFormat $(./swiftformat --version) installed" | |
- name: Run SwiftFormat | |
run: ./swiftformat --lint . --reporter github-actions-log | |
Run-SwiftLint: | |
name: Run SwiftLint | |
runs-on: macos-15 | |
steps: | |
- name: Select Xcode Version | |
uses: maxim-lobanov/setup-xcode@master | |
with: | |
xcode-version: latest | |
- name: Checkout | |
uses: actions/checkout@main | |
- name: Install SwiftLint | |
run: | | |
curl --remote-name --location https://github.com/realm/SwiftLint/releases/latest/download/portable_swiftlint.zip | |
unzip portable_swiftlint.zip | |
echo "SwiftLint $(./swiftlint version) installed" | |
- name: Run SwiftLint Lint Rules | |
run: ./swiftlint lint --strict --reporter github-actions-logging | |
- name: Install xcbeautify | |
run: | | |
latest_xcbeautify_tag=$(gh release --repo cpisciotta/xcbeautify list --json tagName --limit 1 | cut -d "\"" -f 4) | |
curl --location https://github.com/cpisciotta/xcbeautify/releases/download/"$latest_xcbeautify_tag"/xcbeautify-"$latest_xcbeautify_tag"-arm64-apple-macosx.zip --output xcbeautify.zip | |
unzip xcbeautify.zip | |
echo "xcbeautify $(./xcbeautify --version) installed" | |
- name: Build Genius | |
run: | | |
set -o pipefail | |
xcodebuild build -scheme Genius -destination generic/platform=macOS -skipPackagePluginValidation | tee xcodebuild.log | ./xcbeautify --disable-logging --renderer github-actions | |
- name: Run SwiftLint Analyzer Rules | |
run: ./swiftlint analyze --strict --reporter github-actions-logging --compiler-log-path xcodebuild.log | |
Run-Tests: | |
name: Run Tests | |
runs-on: macos-15 | |
steps: | |
- name: Select Xcode Version | |
uses: maxim-lobanov/setup-xcode@master | |
with: | |
xcode-version: latest | |
- name: Checkout | |
uses: actions/checkout@main | |
- name: Install xcbeautify | |
run: | | |
latest_xcbeautify_tag=$(gh release --repo cpisciotta/xcbeautify list --json tagName --limit 1 | cut -d "\"" -f 4) | |
curl --location https://github.com/cpisciotta/xcbeautify/releases/download/"$latest_xcbeautify_tag"/xcbeautify-"$latest_xcbeautify_tag"-arm64-apple-macosx.zip --output xcbeautify.zip | |
unzip xcbeautify.zip | |
echo "xcbeautify $(./xcbeautify --version) installed" | |
- name: Run Tests | |
run: | | |
set -o pipefail | |
xcodebuild test -scheme Genius -destination platform=macOS,arch=arm64 -skipPackagePluginValidation | ./xcbeautify --disable-logging --renderer github-actions | |
Build-Genius: | |
name: Build Genius | |
runs-on: macos-15 | |
permissions: | |
id-token: write | |
attestations: write | |
steps: | |
- name: Select Xcode Version | |
uses: maxim-lobanov/setup-xcode@master | |
with: | |
xcode-version: latest | |
- name: Checkout | |
uses: actions/checkout@main | |
- name: Install xcbeautify | |
run: | | |
latest_xcbeautify_tag=$(gh release --repo cpisciotta/xcbeautify list --json tagName --limit 1 | cut -d "\"" -f 4) | |
curl --location https://github.com/cpisciotta/xcbeautify/releases/download/"$latest_xcbeautify_tag"/xcbeautify-"$latest_xcbeautify_tag"-arm64-apple-macosx.zip --output xcbeautify.zip | |
unzip xcbeautify.zip | |
echo "xcbeautify $(./xcbeautify --version) installed" | |
- name: Build Genius | |
run: | | |
set -o pipefail | |
xcodebuild archive -scheme Genius -destination generic/platform=macOS -archivePath Genius -skipPackagePluginValidation | ./xcbeautify --disable-logging --renderer github-actions | |
- name: Zip Genius | |
run: | | |
mv Genius.xcarchive/Products/Applications/Genius.app . | |
zip --recurse-paths Genius.zip Genius.app | |
- name: Attest Build Provenance | |
uses: actions/attest-build-provenance@main | |
with: | |
subject-path: Genius.zip | |
- name: Upload Genius | |
uses: actions/upload-artifact@main | |
with: | |
name: Genius | |
path: Genius.zip | |
- name: Zip Debug Symbols | |
run: | | |
mv Genius.xcarchive/dSYMs/Genius.app.dSYM . | |
zip --recurse-paths DebugSymbols.zip Genius.app.dSYM | |
- name: Upload Debug Symbols | |
uses: actions/upload-artifact@main | |
with: | |
name: Debug Symbols | |
path: DebugSymbols.zip |