ci(ios): run lint checks #13
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
on: | |
pull_request: | |
paths: | |
- 'ios/**' | |
jobs: | |
lint_and_tests: | |
runs-on: macos-latest | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v4 | |
with: | |
# Fetch the full history to access the base commit | |
fetch-depth: 0 | |
- name: Set up Swift | |
uses: fwal/setup-swift@v2 | |
with: | |
swift-version: '5.10' | |
- name: Select Xcode Version | |
run: sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer | |
- name: Clean Derived Data | |
run: | | |
rm -rf ~/Library/Developer/Xcode/DerivedData | |
- name: Run SwiftLint on Changed Files | |
uses: cirruslabs/swiftlint-action@v2 | |
with: | |
args: --strict --quiet --git diff ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }} |