Set up pre-commit hooks
This commit is contained in:
parent
5a08abf60b
commit
e9eb300499
3 changed files with 27 additions and 0 deletions
|
|
@ -35,6 +35,7 @@ network-manager \
|
||||||
nmap \
|
nmap \
|
||||||
pipx \
|
pipx \
|
||||||
postfix \
|
postfix \
|
||||||
|
pre-commit \
|
||||||
pulseaudio \
|
pulseaudio \
|
||||||
pulseaudio-utils \
|
pulseaudio-utils \
|
||||||
python3-poetry \
|
python3-poetry \
|
||||||
|
|
|
||||||
|
|
@ -6,3 +6,5 @@ systemctl --user enable syncthing.service
|
||||||
systemctl --user start syncthing.service
|
systemctl --user start syncthing.service
|
||||||
|
|
||||||
mkdir -p ~/Pictures/screenshots
|
mkdir -p ~/Pictures/screenshots
|
||||||
|
|
||||||
|
pre-commit install
|
||||||
|
|
|
||||||
24
.pre-commit-config.yaml
Normal file
24
.pre-commit-config.yaml
Normal file
|
|
@ -0,0 +1,24 @@
|
||||||
|
repos:
|
||||||
|
- repo: https://github.com/pre-commit/pre-commit-hooks
|
||||||
|
rev: v2.3.0
|
||||||
|
hooks:
|
||||||
|
- id: check-ast
|
||||||
|
- id: check-executables-have-shebangs
|
||||||
|
- id: check-toml
|
||||||
|
- id: check-yaml
|
||||||
|
- id: end-of-file-fixer
|
||||||
|
exclude: ^\.config/fcitx5/
|
||||||
|
- id: trailing-whitespace
|
||||||
|
- repo: https://github.com/psf/black
|
||||||
|
rev: 22.10.0
|
||||||
|
hooks:
|
||||||
|
- id: black
|
||||||
|
- repo: https://github.com/pycqa/isort
|
||||||
|
rev: 5.12.0
|
||||||
|
hooks:
|
||||||
|
- id: isort
|
||||||
|
- repo: https://github.com/syntaqx/git-hooks
|
||||||
|
rev: v0.0.18
|
||||||
|
hooks:
|
||||||
|
- id: forbid-binary
|
||||||
|
exclude: ^\.local/share/jupyter/kernels/python3\.12/logo-
|
||||||
Loading…
Add table
Add a link
Reference in a new issue