-
Notifications
You must be signed in to change notification settings - Fork 63
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #113 from jameslamb/pre-commit
add pre-commit, other development setup stuff
- Loading branch information
Showing
8 changed files
with
128 additions
and
25 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
name: pr | ||
|
||
on: | ||
push: | ||
pull_request: | ||
|
||
jobs: | ||
checks: | ||
name: "pre-commit hooks" | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: pre-commit/action@v3.0.1 |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
*.7zip | ||
*.a | ||
*.bak | ||
*.bz | ||
*.bz2 | ||
*.conda | ||
*.core | ||
*.coverage | ||
*.css | ||
*.csv | ||
*.dat | ||
*.db | ||
dist/ | ||
*.dll | ||
*.doc | ||
*.docx | ||
*.docm | ||
.DS_Store | ||
*.dylib | ||
*.egg-info/ | ||
*.env | ||
*.exe | ||
*.feather | ||
*.html | ||
htmlcov/ | ||
.idea/ | ||
.ipynb_checkpoints/ | ||
*.js | ||
*.json | ||
*.lzma | ||
.mypy_cache/ | ||
*.npy | ||
*.o | ||
*.pem | ||
*.ppt | ||
*.pptx | ||
*.pptm | ||
*.pq | ||
*.pub | ||
*.pyc | ||
__pycache__/ | ||
.pytest_cache/ | ||
*.rda | ||
*.rds | ||
*.Rdata | ||
*.rsa | ||
.ruff_cache/ | ||
*.snappy-*.tar.gz | ||
*.so | ||
*.sqlite | ||
*.tar.gz | ||
*.tgz | ||
*.tmp | ||
*.whl | ||
*.xls | ||
*.xlsx | ||
*.xlsm | ||
*.zip | ||
*.zstd |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
# Copyright (c) 2024, NVIDIA CORPORATION. | ||
|
||
repos: | ||
- repo: https://github.com/pre-commit/pre-commit-hooks | ||
rev: v5.0.0 | ||
hooks: | ||
- id: trailing-whitespace | ||
- id: end-of-file-fixer | ||
- repo: https://github.com/codespell-project/codespell | ||
rev: v2.3.0 | ||
hooks: | ||
- id: codespell | ||
- repo: https://github.com/shellcheck-py/shellcheck-py | ||
rev: v0.10.0.1 | ||
hooks: | ||
- id: shellcheck | ||
|
||
default_language_version: | ||
python: python3 |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# contributing | ||
|
||
## Linting | ||
|
||
This repo uses `pre-commit` to statically analyze code. | ||
Run the following to do that locally. | ||
|
||
```shell | ||
pre-commit run --all-files | ||
``` |
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
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
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
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