From 3abc837f78a669c48879dc9afce3347f963de529 Mon Sep 17 00:00:00 2001 From: Philipp Horstenkamp Date: Sat, 16 May 2026 16:28:07 +0200 Subject: [PATCH] chore: configure pre-commit stages and add build hook --- .pre-commit-config.yaml | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index c8dd2d3..aeada8f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,3 +1,4 @@ +default_stages: [pre-commit, pre-push, manual] exclude: ^(dist|node_modules)/ repos: - repo: https://github.com/pre-commit/pre-commit-hooks @@ -39,8 +40,18 @@ repos: rev: v6.0.0 hooks: - id: end-of-file-fixer - exclude: (.txt$|.ipynb$|README.md$|readme.mde$) + exclude: (.txt$|.ipynb$|README.md$) - id: trailing-whitespace exclude: (.txt$|README.md$) - id: mixed-line-ending args: [--fix=lf] + +- repo: local + hooks: + - id: build + name: rebuild-distribution + entry: npm run build + language: system + files: ^(index\.js|monitor\.js|package\.json|package-lock\.json)$ + pass_filenames: false + stages: [pre-commit]