mirror of
https://github.com/samsonjs/vibetunnel.git
synced 2026-04-02 10:45:57 +00:00
- Changed swift.yml, rust.yml, and node.yml from direct triggers to workflow_call - This fixes the workflow configuration error causing immediate CI failures - Reusable workflows must use workflow_call when invoked by other workflows
106 lines
No EOL
2.6 KiB
YAML
106 lines
No EOL
2.6 KiB
YAML
name: Swift CI
|
|
|
|
on:
|
|
workflow_call:
|
|
|
|
env:
|
|
DEVELOPER_DIR: /Applications/Xcode_16.3.app/Contents/Developer
|
|
|
|
jobs:
|
|
lint:
|
|
name: Lint Swift Code
|
|
runs-on: macos-15
|
|
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Setup Xcode
|
|
run: |
|
|
sudo xcode-select -s /Applications/Xcode_16.3.app/Contents/Developer
|
|
xcodebuild -version
|
|
swift --version
|
|
|
|
- name: Install linting tools
|
|
run: |
|
|
brew install swiftlint swiftformat
|
|
|
|
- name: Run SwiftFormat (check mode)
|
|
run: swiftformat . --lint
|
|
|
|
- name: Run SwiftLint
|
|
run: swiftlint
|
|
|
|
build-and-test:
|
|
name: Build and Test macOS App
|
|
runs-on: macos-15
|
|
needs: lint
|
|
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Setup Xcode
|
|
run: |
|
|
sudo xcode-select -s /Applications/Xcode_16.3.app/Contents/Developer
|
|
xcodebuild -version
|
|
swift --version
|
|
|
|
- name: Install build tools
|
|
run: |
|
|
brew install xcbeautify
|
|
|
|
- name: Build Debug
|
|
timeout-minutes: 30
|
|
run: |
|
|
set -o pipefail && \
|
|
xcodebuild build \
|
|
-workspace VibeTunnel.xcworkspace \
|
|
-scheme VibeTunnel \
|
|
-configuration Debug \
|
|
-destination "platform=macOS" \
|
|
CODE_SIGN_IDENTITY="" \
|
|
CODE_SIGNING_REQUIRED=NO \
|
|
| xcbeautify
|
|
|
|
- name: Build Release
|
|
timeout-minutes: 30
|
|
run: |
|
|
set -o pipefail && \
|
|
xcodebuild build \
|
|
-workspace VibeTunnel.xcworkspace \
|
|
-scheme VibeTunnel \
|
|
-configuration Release \
|
|
-destination "platform=macOS" \
|
|
CODE_SIGN_IDENTITY="" \
|
|
CODE_SIGNING_REQUIRED=NO \
|
|
| xcbeautify
|
|
|
|
- name: Run tests
|
|
timeout-minutes: 20
|
|
run: |
|
|
set -o pipefail && \
|
|
xcodebuild test \
|
|
-workspace VibeTunnel.xcworkspace \
|
|
-scheme VibeTunnel \
|
|
-configuration Debug \
|
|
-destination "platform=macOS" \
|
|
-resultBundlePath TestResults \
|
|
CODE_SIGN_IDENTITY="" \
|
|
CODE_SIGNING_REQUIRED=NO \
|
|
| xcbeautify
|
|
|
|
- name: Upload test results
|
|
if: failure()
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: swift-test-results
|
|
path: TestResults
|
|
|
|
- name: Upload build artifacts
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: swift-build-artifacts
|
|
path: |
|
|
build/Build/Products/Debug/VibeTunnel.app
|
|
build/Build/Products/Release/VibeTunnel.app |