Extract iOS training library (#29) #8
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: | |
push: | |
paths: | |
- '.github/workflows/swiftformat.yml' | |
- '**.swift' | |
jobs: | |
swiftformat: | |
runs-on: macos-latest | |
name: Check swiftformat | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v3 | |
- name: Install Swift tools | |
run: | | |
curl -LO https://github.com/nicklockwood/SwiftFormat/releases/download/0.51.13/swiftformat.zip | |
unzip swiftformat | |
- name: Format Swift code | |
run: ./swiftformat --verbose . | |
- name: Verify formatted code is unchanged | |
run: | | |
rm -rf __MACOSX swiftformat swiftformat.zip | |
git diff --exit-code HEAD |