Skip to content

created implementation plan#9

Merged
KnisterPeter merged 7 commits into
mainfrom
opencode-workflow-mu9x
Apr 30, 2026
Merged

created implementation plan#9
KnisterPeter merged 7 commits into
mainfrom
opencode-workflow-mu9x

Conversation

@KnisterPeter
Copy link
Copy Markdown
Member

No description provided.

@KnisterPeter KnisterPeter self-assigned this Apr 30, 2026
Markus Wolf added 5 commits April 30, 2026 13:24
Implements parsePatchFrontmatter and applyPatch in src/patch.ts
with unit tests covering all merge rules (description override,
prepend, append, body replace, combinations, empty patch pass-through).
Extends tsdown.config.ts with an onSuccess hook that reads patch files
from src/command-patches/ and applies them to dist/commands/ after the
copy step. Adds src/command-patches/spec.md as the canonical example
using append-only patching.
…comments, extract patch function

- Replace hand-rolled YAML serialization with yaml.stringify to
  correctly handle descriptions containing colons, quotes, and
  other special characters (was silently lossy before)
- Add assertOptionalString guard in parsePatchFrontmatter so
  non-string patch fields throw a clear error instead of producing
  corrupt output at runtime
- Align rule-number comments in applyPatch with the spec's 5-rule
  numbering (was mislabelled as Rules 2/3 instead of 3/4/5)
- Extract onSuccess body into named applyCommandPatches() in
  tsdown.config.ts for readability
- Add three regression tests: colon-in-description round-trip,
  non-string prepend throws, non-string description throws
@KnisterPeter KnisterPeter marked this pull request as ready for review April 30, 2026 13:55
@KnisterPeter KnisterPeter merged commit bca3f5f into main Apr 30, 2026
1 check passed
@KnisterPeter KnisterPeter deleted the opencode-workflow-mu9x branch April 30, 2026 13:57
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