snippetbashTip
pre-commit — Create Git hooks that get run before a commit. More information: <https://pre-commit.com/#command-li
Viewed 0 times
createcommandpre-commitcligetthathooksgit
Problem
How to use the
pre-commit command: Create Git hooks that get run before a commit. More information: <https://pre-commit.com/#command-line-interface>.Solution
pre-commit — Create Git hooks that get run before a commit. More information: <https://pre-commit.com/#command-line-interface>.Install pre-commit into your Git hooks:
pre-commit installRun pre-commit hooks on all staged files:
pre-commit runRun pre-commit hooks on all files, staged or unstaged:
pre-commit run --all-filesClean pre-commit cache:
pre-commit cleanUpdate pre-commit configuration file to the latest repos' versions:
pre-commit autoupdateCode Snippets
Install pre-commit into your Git hooks
pre-commit installRun pre-commit hooks on all staged files
pre-commit runRun pre-commit hooks on all files, staged or unstaged
pre-commit run --all-filesClean pre-commit cache
pre-commit cleanUpdate pre-commit configuration file to the latest repos' versions
pre-commit autoupdateContext
tldr-pages: common/pre-commit
Revisions (0)
No revisions yet.