Skip to content

feat(cli): support local code directives - #2259

Draft
kadymov wants to merge 2 commits into
masterfrom
DOCSTOOLS-6666-code-directive
Draft

kadymov wants to merge 2 commits into
masterfrom
DOCSTOOLS-6666-code-directive

Conversation

@kadymov

@kadymov kadymov commented Sep 14, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add OSS CLI support for local {% code %} directives in HTML and md2md builds
  • support relative/input-root paths, lang, numeric and marker ranges, and keep-indents
  • keep fenced examples and jsonpath directives unchanged for compatibility
  • report invalid ranges and inaccessible files as build errors with safe placeholders
  • add focused unit and integration coverage

Testing

  • npm test — 2008 passed, 1 skipped
  • npm run typecheck
  • npm run lint
  • npm run build
  • npx vitest run -c vitest.integration.config.ts tests/e2e/code-includer.spec.ts
  • built the documentation repository with the locally built CLI

Related

@sonarqubecloud

Copy link
Copy Markdown

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