From 14c75c3f2181b2a6327ddb90eb342be867a5cfaf Mon Sep 17 00:00:00 2001 From: Ashwin Bharambe Date: Mon, 18 Nov 2024 18:17:41 -0800 Subject: [PATCH] Update CONTRIBUTING to include info about pre-commit --- CONTRIBUTING.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 5e19e73b7..4713f564a 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -31,6 +31,19 @@ make html sphinx-autobuild source build/html ``` +## Pre-commit Hooks + +We use [pre-commit](https://pre-commit.com/) to run linting and formatting checks on your code. You can install the pre-commit hooks by running: + +```bash +$ cd llama-stack +$ conda activate +$ pip install pre-commit +$ pre-commit install +``` + +After that, pre-commit hooks will run automatically before each commit. + ## Contributor License Agreement ("CLA") In order to accept your pull request, we need you to submit a CLA. You only need to do this once to work on any of Meta's open source projects.