Skip to content

fix(hooks): strip an empty frontmatter block from the injected ruleset - #265

Closed
SU-AN-coder wants to merge 1 commit into
ayghri:mainfrom
SU-AN-coder:fix/hooks-empty-frontmatter
Closed

SU-AN-coder wants to merge 1 commit into
ayghri:mainfrom
SU-AN-coder:fix/hooks-empty-frontmatter

Conversation

@SU-AN-coder

Copy link
Copy Markdown

The SessionStart hook's pattern required at least one line between the YAML delimiters, so a block with no keys (--- on the first two lines) stayed in the injected ruleset and the reader got the fences. always-on.sh and always-on.ps1 already strip it, so this also restores parity across the runtimes. The OpenCode plugin carries the same pattern and gets the same one-line change.

Summary

Authorship and provenance — select exactly one

  • Human-authored — substantive implementation and text were produced by a human.
  • Autonomous agent-authored — an agent planned and produced most of the substantive change.
  • Hybrid — a human and one or more agents both made substantive contributions.

Agent/tool and model/version:

Agent contribution:

Human verification:

Known limitations or uncertain results:

Labels

Target label:

Author label:

Workflow labels:

Safety and side effects

  • The change does not access or expose secrets, private files, or unrelated user/repository data.
  • Scripts, hooks, workflows, and evals are bounded and do not create surprising or irreversible side effects.
  • No destructive, privileged, production, externally visible, or persistent action occurs without explicit user intent and appropriate safeguards.
  • Network access, third-party code, permissions, and provider costs are minimized and documented.
  • Prompt text, examples, and fixtures contain no hidden instructions that weaken safety or expand agent authority.

Side effects, permissions, network access, and cost:

Compatibility

  • This is not a breaking change.
  • This is a breaking change; it was discussed, and migration/deprecation documentation is included below.
  • Canonical and mirrored skill files are synchronized when applicable.
  • Relevant platform manifests and installation documentation were reviewed.

Migration or rollback notes:

Verification

  • <command> — <result>

Behavior evals:

Final accountability

  • I reviewed the complete diff, removed unrelated generated changes, and take responsibility for the submitted content.
  • All failed, skipped, or unrun checks are disclosed above.

The SessionStart hook's pattern required at least one line between the YAML
delimiters, so a block with no keys (--- on the first two lines) stayed in the
injected ruleset and the reader got the fences. always-on.sh and always-on.ps1
already strip it, so this also restores parity across the runtimes. The
OpenCode plugin carries the same pattern and gets the same one-line change.
@SU-AN-coder

Copy link
Copy Markdown
Author

Closing this one. The repository has not merged a pull request in the last two weeks, and leaving the PR sitting here indefinitely helps nobody. The branch is untouched — reopen it or say so and I will, whenever the project starts taking changes again.

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