Skip to main content

Pre-commit hook

Pre-commit is a multi-language package manager for pre-commit hooks. You specify a list of hooks you want and pre-commit manages the installation and execution of the hooks.

# sample .pre-commit-config.yaml for a project that would like to use datree with pre-commit
- repo:
# rev is the .pre-commit-hooks.yaml version
# could also be a version or a release tag
rev: HEAD
- id: datree-docker

The pre-commit hook is using our docker image to run Datree CLI to it requires to have docker installed on the machine.