From ad8fbc37dc24e0297da39fb060bdd4d2a48d7813 Mon Sep 17 00:00:00 2001 From: Jason Stirnaman Date: Wed, 4 Jun 2025 17:40:53 -0500 Subject: [PATCH] fix(lefthook): Incorrect glob patterns. Add linting for influxdb3/explorer --- lefthook.yml | 55 +++++++++++++++++++++++++++++++++++++++------------- 1 file changed, 42 insertions(+), 13 deletions(-) diff --git a/lefthook.yml b/lefthook.yml index a3f2ae759..89366fda8 100644 --- a/lefthook.yml +++ b/lefthook.yml @@ -22,21 +22,49 @@ pre-commit: --minAlertLevel=error {staged_files}' cloud-dedicated-lint: tags: lint,v3 - glob: 'content/influxdb/cloud-dedicated/*.md' + glob: + - 'content/influxdb3/cloud-dedicated/*.md' + - 'content/shared/*.md' run: '.ci/vale/vale.sh - --config=content/influxdb/cloud-dedicated/.vale.ini + --config=content/influxdb3/cloud-dedicated/.vale.ini --minAlertLevel=error {staged_files}' cloud-serverless-lint: tags: lint,v3 - glob: 'content/influxdb/cloud-serverless/*.md' + glob: + - 'content/influxdb/cloud-serverless/*.md' + - 'content/shared/*.md' run: '.ci/vale/vale.sh - --config=content/influxdb/cloud-serverless/.vale.ini + --config=content/influxdb3/cloud-serverless/.vale.ini --minAlertLevel=error {staged_files}' clustered-lint: tags: lint,v3 - glob: 'content/influxdb/clustered/*.md' + glob: + - 'content/influxdb3/clustered/*.md' + - 'content/shared/*.md' run: '.ci/vale/vale.sh - --config=content/influxdb/cloud-serverless/.vale.ini + --config=content/influxdb3/cloud-serverless/.vale.ini + --minAlertLevel=error {staged_files}' + core-lint: + tags: lint,v3 + glob: + - 'content/influxdb3/core/*.md' + - 'content/shared/*.md' + run: '.ci/vale/vale.sh + --config=.vale.ini + --minAlertLevel=error {staged_files}' + enterprise-lint: + tags: lint,v3 + glob: + - 'content/influxdb3/enterprise/*.md' + - 'content/shared/*.md' + run: '.ci/vale/vale.sh + --config=.vale.ini + --minAlertLevel=error {staged_files}' + explorer-lint: + tags: lint,clients + glob: 'content/influxdb3/explorer/*.md' + run: '.ci/vale/vale.sh + --config=.vale.ini --minAlertLevel=error {staged_files}' telegraf-lint: tags: lint,clients @@ -77,7 +105,7 @@ pre-push: e2e-links: tags: test,links - glob: 'content/**/*.{md,html}' + glob: 'content/*.{md,html}' run: | echo "Running link checker for: {push_files}" yarn test:links {push_files} @@ -94,9 +122,10 @@ pre-push: build-pytest-image: tags: test run: yarn build:pytest:image + # Test code blocks in markdown files cloud-pytest: - glob: content/influxdb/cloud/**/*.md + glob: content/influxdb/cloud/*.md tags: test,codeblocks,v2 env: SERVICE: cloud-pytest @@ -104,35 +133,35 @@ pre-push: cloud-dedicated-pytest: tags: test,codeblocks,v3 - glob: content/influxdb/cloud-dedicated/**/*.md + glob: content/influxdb3/cloud-dedicated/*.md run: | yarn test:codeblocks:cloud-dedicated '{push_files}' && ./test/scripts/monitor-tests.sh stop cloud-dedicated-pytest cloud-serverless-pytest: tags: test,codeblocks,v3 - glob: content/influxdb/cloud-serverless/**/*.md + glob: content/influxdb3/cloud-serverless/*.md env: SERVICE: cloud-serverless-pytest run: yarn test:codeblocks:cloud-serverless '{push_files}' clustered-pytest: tags: test,codeblocks,v3 - glob: content/influxdb/clustered/**/*.md + glob: content/influxdb3/clustered/*.md run: | yarn test:codeblocks:clustered '{push_files}' && ./test/scripts/monitor-tests.sh stop clustered-pytest telegraf-pytest: tags: test,codeblocks - glob: content/telegraf/**/*.md + glob: content/telegraf/*.md env: SERVICE: telegraf-pytest run: yarn test:codeblocks:telegraf '{push_files}' v2-pytest: tags: test,codeblocks,v2 - glob: content/influxdb/v2/**/*.md + glob: content/influxdb/v2/*.md env: SERVICE: v2-pytest run: yarn test:codeblocks:v2 '{push_files}' \ No newline at end of file