Skip to content

Commit

Permalink
Remove old pre-commit hooks script as new approach exists (mapbox#2253)
Browse files Browse the repository at this point in the history
  • Loading branch information
aleksproger authored Aug 14, 2024
1 parent cc7bbe9 commit 5c7f91b
Show file tree
Hide file tree
Showing 4 changed files with 34 additions and 25 deletions.
28 changes: 28 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v3.2.0
hooks:
- id: trailing-whitespace
exclude: LICENSE.md
- id: end-of-file-fixer
- id: check-yaml
- id: check-json
exclude: .vscode/.*.json
- id: check-byte-order-marker
- id: check-merge-conflict
- repo: "https://github.com/realm/SwiftLint"
rev: 0.55.1
hooks:
- id: swiftlint
entry: swiftlint --fix --strict
- repo: https://github.com/psf/black
rev: 24.4.2
hooks:
- id: black
language_version: python3.12
- repo: https://github.com/gitleaks/gitleaks
rev: v8.16.1
hooks:
- id: gitleaks
12 changes: 6 additions & 6 deletions DEVELOPING.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,13 @@ This project:
to manage dependencies for development. CocoaPods is supported for *consuming*
the SDK.

5. uses [secret-shield](https://github.com/mapbox/secret-shield) to help block
secrets such as access tokens from being exposed. Setup `secret-shield` by running:
5. Install pre-commit hooks
```bash
brew install xcodegen swiftlint
pip install pre-commit

```sh
npm install -g @mapbox/secret-shield
scripts/install-pre-commit/install-pre-commit.sh
```
pre-commit install # Installs the pre-commit hooks
```

6. uses CircleCI and Firebase Test Lab for continuous integration.

Expand Down
8 changes: 0 additions & 8 deletions scripts/install-pre-commit/install-pre-commit.sh

This file was deleted.

11 changes: 0 additions & 11 deletions scripts/install-pre-commit/pre-commit.sh

This file was deleted.

0 comments on commit 5c7f91b

Please sign in to comment.