From 2791aa1672861c42fcc388872aa2243406fd7a0c Mon Sep 17 00:00:00 2001 From: Mikita Sakalouski <38785549+mikita-sakalouski@users.noreply.github.com> Date: Wed, 2 Oct 2024 00:47:40 +0200 Subject: [PATCH] feat: add new pre-commit hooks for managing Hatch project requirements --- .pre-commit-hooks.yaml | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/.pre-commit-hooks.yaml b/.pre-commit-hooks.yaml index 969320ce1..ae5ffb92e 100644 --- a/.pre-commit-hooks.yaml +++ b/.pre-commit-hooks.yaml @@ -4,4 +4,25 @@ entry: hatch language: python minimum_pre_commit_version: 2.9.2 + require_serial: true +- id: hatch-requirements-project-only + name: hatch-requirements-project-only + description: "Hatch: Write project requirements to requirements.txt" + entry: "sh -c 'hatch dep show requirements > requirements.txt'" + language: python + minimum_pre_commit_version: 2.9.2 + require_serial: true +- id: hatch-requirements-env-only + name: hatch-requirements-env-only + description: "Hatch: Write project requirements to requirements.txt" + entry: "sh -c 'hatch dep show requirements > requirements.txt'" + language: python + minimum_pre_commit_version: 2.9.2 + require_serial: true +- id: hatch-requirements-all + name: hatch-requirements-all + description: "Hatch: Write project requirements to requirements.txt" + entry: "sh -c 'hatch dep show requirements > requirements.txt'" + language: python + minimum_pre_commit_version: 2.9.2 require_serial: true \ No newline at end of file