This repository was archived by the owner on Dec 9, 2025. It is now read-only.
v3.3.2 #47
This file contains hidden or 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: Linters | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| swiftlint: | |
| name: Run SwiftLint | |
| runs-on: macos-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: SwiftyLab/setup-swift@latest | |
| with: | |
| swift-version: "6.2" | |
| - name: Install SwiftLint | |
| run: brew install swiftlint | |
| - name: Run SwiftLint | |
| run: swiftlint --strict | |
| swift-format: | |
| name: Run swift-format | |
| runs-on: ubuntu-latest | |
| container: | |
| image: swift:latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install dependencies | |
| run: apt-get update && apt-get install -y wget | |
| - name: Download .swift-format config | |
| run: wget -O .swift-format https://gist.githubusercontent.com/RISCfuture/e0c21afb7bd80a88d128a42bf40d2ecd/raw/.swift-format | |
| - name: Install swift-format | |
| run: | | |
| git clone https://github.com/swiftlang/swift-format.git | |
| cd swift-format | |
| swift build -c release | |
| cp .build/release/swift-format /usr/local/bin/ | |
| - name: Run swift-format lint | |
| run: swift-format lint -r . |