summaryrefslogtreecommitdiffhomepage
path: root/CONTRIBUTING.md
diff options
context:
space:
mode:
authorYukihiro "Matz" Matsumoto <[email protected]>2021-03-02 16:53:33 +0900
committerGitHub <[email protected]>2021-03-02 16:53:33 +0900
commit187384124ba37e3c057262d1a205f1afce117af1 (patch)
tree9d8a955df4196f82aba42a64f7f420db181b54d5 /CONTRIBUTING.md
parent55ac5dba868c317e6ae7f7284fe783fce8bc823a (diff)
parent1c9b1bfeb7932c1b82509679e40b2d2bf99768cc (diff)
downloadmruby-187384124ba37e3c057262d1a205f1afce117af1.tar.gz
mruby-187384124ba37e3c057262d1a205f1afce117af1.zip
Merge pull request #5368 from jbampton/add-pre-commit-framework
feat: add pre-commit framework
Diffstat (limited to 'CONTRIBUTING.md')
-rw-r--r--CONTRIBUTING.md9
1 files changed, 9 insertions, 0 deletions
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 2ffd759b1..7e48508aa 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -18,6 +18,15 @@ things in mind before submitting your pull request:
* Use mrbgem to provide non ISO features (classes, modules and methods) unless
you have a special reason to implement them in the core
+## Pre-commit
+
+A framework for managing and maintaining multi-language pre-commit hooks.
+Pre-commit can be [installed](https://pre-commit.com/#installation) with `pip`, `curl`, `brew` or `conda`.
+You need to first install pre-commit and then install the pre-commit hooks with `pre-commit install`.
+Now pre-commit will run automatically on git commit!
+It's usually a good idea to run the hooks against all the files when adding new hooks (usually pre-commit will only run on the changed files during git hooks).
+Use `pre-commit run --all-files` to check all files.
+
## Coding conventions
How to style your C and Ruby code which you want to submit.