Skip to content

feat(ci): add Vale style check workflow#6816

Open
jstirnaman wants to merge 9 commits intomasterfrom
docs-v2-jts-vale-ci
Open

feat(ci): add Vale style check workflow#6816
jstirnaman wants to merge 9 commits intomasterfrom
docs-v2-jts-vale-ci

Conversation

@jstirnaman
Copy link
Contributor

Summary

Adds Vale style linting to GitHub Actions that blocks PRs on errors and provides actionable feedback.

Changes:

  • .github/scripts/resolve-shared-content.sh - Resolves shared content files to their consuming product pages
  • .github/scripts/vale-check.sh - Maps files to product-specific Vale configs and runs Vale via Docker
  • .github/workflows/pr-vale-check.yml - CI workflow with annotations and PR comments

Test plan

  • Vale workflow runs on this PR
  • Test file triggers Vale errors (intentional)
  • Annotations appear on changed lines
  • PR comment is posted with results
  • Check fails due to errors (as expected)
  • Remove test file and verify check passes

@jstirnaman jstirnaman requested a review from a team as a code owner February 11, 2026 23:16
@jstirnaman jstirnaman requested review from sanderson and removed request for a team February 11, 2026 23:16
@github-actions
Copy link
Contributor

github-actions bot commented Feb 11, 2026

Vale Style Check Results

Metric Count
Errors 0
Warnings 16
Suggestions 16
Warnings (16)
File Line Rule Message
DOCS-TESTING.md 16 write-good.TooWordy 'Validate' is too wordy.
DOCS-TESTING.md 76 write-good.Passive 'be deleted' may be passive voice. Use active voice if you can.
DOCS-TESTING.md 77 write-good.Passive 'is configured' may be passive voice. Use active voice if you can.
DOCS-TESTING.md 193 write-good.TooWordy 'additional' is too wordy.
DOCS-TESTING.md 239 write-good.TooWordy 'validate' is too wordy.
DOCS-TESTING.md 338 write-good.TooWordy 'validate' is too wordy.
DOCS-TESTING.md 361 write-good.Passive 'is distributed' may be passive voice. Use active voice if you can.
DOCS-TESTING.md 425 write-good.Passive 'is required' may be passive voice. Use active voice if you can.
DOCS-TESTING.md 464 write-good.Passive 'be found' may be passive voice. Use active voice if you can.
DOCS-TESTING.md 465 write-good.TooWordy 'validate' is too wordy.
DOCS-TESTING.md 532 write-good.TooWordy 'modify' is too wordy.
DOCS-TESTING.md 619 write-good.TooWordy 'modify' is too wordy.
DOCS-TESTING.md 741 write-good.Passive 'are evaluated' may be passive voice. Use active voice if you can.
DOCS-TESTING.md 742 write-good.Passive 'are removed' may be passive voice. Use active voice if you can.
DOCS-TESTING.md 749 write-good.TooWordy 'Monitor' is too wordy.
DOCS-TESTING.md 776 write-good.TooWordy 'substantial' is too wordy.

Check passed

@github-actions
Copy link
Contributor

PR Preview Action v1.4.8
🚀 Deployed preview to https://influxdata.github.io/docs-v2/pr-preview/pr-6816/
on branch gh-pages at 2026-02-11 23:19 UTC

@github-actions
Copy link
Contributor

PR Preview

Status Details
Preview View preview
Pages 1 page(s) deployed
Build time 66s
Last updated 2026-02-11 23:19:11 UTC
Pages included in this preview
  • /influxdb3/core/test-vale-errors/

Preview auto-deploys on push. Will be cleaned up when PR closes.

Design for adding Vale style linting to GitHub Actions PR checks:
- Block merging on style errors
- Inline annotations + PR summary comments
- Smart config detection per product area
- Shared content resolution script (reusable by other workflows)
- Docker-based Vale execution (matches local setup)
Detailed step-by-step plan for implementing Vale CI:
- Task 1: Shared content resolution script
- Task 2: Vale check script with config mapping
- Task 3: GitHub Actions workflow
- Task 4: Testing procedure
- Task 5: Documentation updates
- Task 6: Final verification
Resolves content/shared/* files to their consuming product pages
by searching for matching source: frontmatter. Reusable by Vale,
link-checker, and other workflows that need shared content expansion.
Maps files to product-specific Vale configs matching lefthook.yml:
- cloud-dedicated, cloud-serverless, v2 use product configs
- Other content uses root .vale.ini
- Non-content uses .vale-instructions.ini

Runs Vale via Docker for version consistency with local dev.
Runs Vale on PR changes with product-specific configs:
- Blocks merging on errors
- Shows warnings/suggestions as annotations
- Posts summary comment for humans and AI agents
- Uses Docker for Vale version consistency
Add `|| [[ -n "$f" ]]` to while read loops to catch the last line
even when input doesn't end with a newline. This is a common bash
pitfall where `while read` skips the final line without a terminator.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant