Enable post commit run of pre-commit hooks over all files. (#3245)

The pre-commit hook will only run on changed files, whereas this runs on
push and will check everything.
pull/3246/head
Stella Laurenzo 2024-04-27 14:24:52 -07:00 committed by GitHub
parent 6877302504
commit a339d7bb5a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 16 additions and 1 deletions

View File

@ -0,0 +1,15 @@
name: pre-commit (all files on push)
on:
push:
branches: [main, post-commit-test]
jobs:
pre-commit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v3
- uses: pre-commit/action@v3.0.1
with:
extra_args: --color=always --all-files

View File

@ -1,6 +1,6 @@
# See https://pre-commit.com for more information # See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks # See https://pre-commit.com/hooks.html for more hooks
exclude: "GeneratedTorchOps\\.td|abstract_interp_lib_gen\\.py|\\.excalidraw" exclude: "GeneratedTorchOps\\.td|abstract_interp_lib_gen\\.py|\\.excalidraw|\\.ipynb"
repos: repos:
- repo: https://github.com/pre-commit/pre-commit-hooks - repo: https://github.com/pre-commit/pre-commit-hooks
rev: v3.2.0 rev: v3.2.0