PureXML/third_party/rules-swift/.pre-commit-config.yaml
Mihaela Mihaljevic c7ef8abfd9 chore(rules): pin rules-swift corpus, add gates and CI; drop redundant docs/rules mirror
Adopt the rules-swift pin-and-codify strategy in snapshot mode (third_party/rules-swift
@97dc70f + sha256), add codified gates, a conformance audit ledger, and
.github/workflows/rules-swift.yml (corpus-pin integrity required, full gate report mode).
Remove the docs/rules mirror it supersedes (repo-specific files kept under docs/). Style
and leak gates exclude the vendored corpus.
2026-06-30 14:02:40 +02:00

28 lines
925 B
YAML

# pre-commit framework configuration. https://pre-commit.com
# Install once per clone:
# pip install pre-commit
# pre-commit install
# pre-commit install --hook-type commit-msg
# These run the locally installed SwiftFormat and SwiftLint, so there are no tool
# versions to pin here; pin them through your toolchain instead.
repos:
- repo: local
hooks:
- id: swiftformat
name: SwiftFormat
entry: swiftformat --lint --config .swiftformat .
language: system
types: [swift]
pass_filenames: false
- id: swiftlint
name: SwiftLint
entry: swiftlint --config .swiftlint.yml --strict
language: system
types: [swift]
pass_filenames: false
- id: commit-message-checks
name: No tool attribution or em dashes in the commit message
entry: .githooks/commit-msg
language: script
stages: [commit-msg]