Skip to content

Commit da37026

Browse files
kylehowellsclaude
andcommitted
Run lint on Linux with prebuilt swiftformat binary
Downloads the prebuilt Linux binary from SwiftFormat releases instead of building from source or requiring macOS. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <[email protected]>
1 parent 4b36567 commit da37026

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

.github/workflows/test.yml

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,15 +49,18 @@ jobs:
4949
- name: Run tests
5050
run: swift test
5151

52-
# Lint - only runs on tag pushes (releases)
52+
# Lint - runs on every push (Linux)
5353
lint:
54-
runs-on: macos-latest
55-
if: startsWith(github.ref, 'refs/tags/')
54+
runs-on: ubuntu-latest
5655
steps:
5756
- uses: actions/checkout@v4
5857

5958
- name: Install swiftformat
60-
run: brew install swiftformat
59+
run: |
60+
wget -q https://github.com/nicklockwood/SwiftFormat/releases/download/0.54.6/swiftformat_linux.zip
61+
unzip -q swiftformat_linux.zip
62+
chmod +x swiftformat_linux
63+
sudo mv swiftformat_linux /usr/local/bin/swiftformat
6164
6265
- name: Lint
6366
run: swiftformat --lint . --reporter github-actions-log

0 commit comments

Comments
 (0)