Skip to content

Follow-up to #236: fail hard on fmt errors, trim abort output, render SKILL.md first#242

Merged
schpet merged 1 commit into
mainfrom
oss-pr-lander/236
Jul 14, 2026
Merged

Follow-up to #236: fail hard on fmt errors, trim abort output, render SKILL.md first#242
schpet merged 1 commit into
mainfrom
oss-pr-lander/236

Conversation

@schpet

@schpet schpet commented Jul 14, 2026

Copy link
Copy Markdown
Owner

Follow-up to #236. A small corrective delta stacked on top of that PR's generator hardening; it will be rebased down to only the delta once #236 lands.

This delta was blind-planned: two independent planners designed the generator fix from a solution-stripped problem statement (without seeing #236), and both independently flagged the three gaps below that #236 left open.

What this changes in skills/linear-cli/scripts/generate-docs.ts

  • deno fmt failure is now fatal instead of a logged warning. The format step runs after the docs are written, so a silent failure would leave unformatted docs that break deno fmt --check in CI once committed.
  • The top-level error boundary prints a concise message (Error: <message>) instead of the raw error object and its stack trace, on every abort path (missing binary, failed help fetch, fmt failure).
  • SKILL.md is rendered from its template before writeReferences prunes any stale docs, so a missing or broken template aborts before the references directory is touched — extending refactor(skill-docs): harden generator and make output deterministic #236's own "write before prune / abort before write" invariant to the template read.

None of these change the generated doc output — they are pure control-flow/error-handling. deno task generate-skill-docs remains idempotent.

Note: while this branch is a draft it still contains #236's commits. The first CI run therefore diffs the superset (#236 + this delta) against main; after #236 merges, this will be rebased to only the delta and marked ready.

… SKILL.md first

Corrective delta on top of #236's generator hardening:

- deno fmt failure is now fatal instead of a logged warning; unformatted
  committed docs would otherwise break `deno fmt --check` in CI.
- The top-level error boundary prints a concise message instead of the raw
  error (and its stack trace) on every abort path.
- SKILL.md is rendered from its template before writeReferences prunes any
  stale docs, so a missing or broken template aborts before touching the
  references directory.
@schpet
schpet force-pushed the oss-pr-lander/236 branch from bd42812 to 48c5b5c Compare July 14, 2026 03:51
@schpet
schpet marked this pull request as ready for review July 14, 2026 03:51
@schpet
schpet merged commit 82daad7 into main Jul 14, 2026
15 checks passed
@schpet
schpet deleted the oss-pr-lander/236 branch July 14, 2026 03:53
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