Skip to content

Add docs syntax check workflow for docs/en Markdown#25415

Merged
enisn merged 5 commits into
devfrom
maliming/check-docs-syntax-action
May 12, 2026
Merged

Add docs syntax check workflow for docs/en Markdown#25415
enisn merged 5 commits into
devfrom
maliming/check-docs-syntax-action

Conversation

@maliming

Copy link
Copy Markdown
Member

Adds a CI check that validates the Scriban template syntax inside docs/en/**/*.md whenever a PR touches them. The checker is a small .NET console app that runs Template.Parse plus a strict-mode render, with the same parameter dictionary the docs renderer injects at runtime, so escape issues are surfaced before they reach the published documentation site.

The workflow only inspects markdown files changed by the PR, plus docs/en/docs-params.json so that parameter file changes also trigger validation against a known-clean page.

Copilot AI review requested due to automatic review settings May 12, 2026 12:52

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a PR-only CI workflow to validate Scriban template parsing/rendering for changed docs/en/**/*.md files, aiming to catch template syntax/variable issues before docs are published.

Changes:

  • Introduces a new GitHub Actions workflow that gathers PR-changed Markdown files (and detects docs-params.json changes) and runs a syntax checker against them.
  • Adds a small .NET console app that parses Scriban templates and performs a strict-mode render with injected parameter keys.
  • Adds a dedicated .csproj for the checker with a Scriban dependency.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

File Description
.github/workflows/check-docs-syntax.yml New PR workflow to build and run the Scriban syntax checker on changed docs/en markdown (or index.md when only params changed).
.github/scripts/CheckDocsSyntax/Program.cs Implements Markdown enumeration, Scriban parse diagnostics, strict render pass, and GitHub Actions annotations.
.github/scripts/CheckDocsSyntax/CheckDocsSyntax.csproj Adds the .NET console project for the checker with Scriban package reference.

Comment thread .github/scripts/CheckDocsSyntax/Program.cs
@github-actions

github-actions Bot commented May 12, 2026

Copy link
Copy Markdown
Contributor

Docs syntax check passed

The previously reported issues are no longer present in this PR.

@maliming maliming added this to the 10.5-preview milestone May 12, 2026
@maliming maliming requested a review from enisn May 12, 2026 13:11
@enisn enisn merged commit dbd74e7 into dev May 12, 2026
2 checks passed
@enisn enisn deleted the maliming/check-docs-syntax-action branch May 12, 2026 13:13
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.

3 participants