Skip to content

πŸ› fix: make .extra.tmpl actually renderable by op inject - #11

Merged
hadees merged 2 commits into
masterfrom
fix/extra-tmpl-op-inject
Jul 13, 2026
Merged

πŸ› fix: make .extra.tmpl actually renderable by op inject#11
hadees merged 2 commits into
masterfrom
fix/extra-tmpl-op-inject

Conversation

@hadees

@hadees hadees commented Jul 13, 2026

Copy link
Copy Markdown
Owner

Summary

op inject parses the entire template β€” comments included β€” and errors on any curly-brace pair or bare op:// text that isn't a real brace-wrapped secret reference. .extra.tmpl's self-documenting comments contained both, so every render has always failed, including the one bootstrap runs (whose error message misattributed it to auth).

  • Template is stripped to a pointer + parser warning; the how-to (with literal example syntax, which is only safe outside the template) moves to CLAUDE.md under "Machine-local secrets".
  • New tests/extra-tmpl.bats enforces the invariant on CI without needing the op CLI: no braces or op:// in comments, and active references must be {{ op://vault/item/field }}-shaped.

Test plan

  • op inject -i .extra.tmpl renders cleanly (verified locally; no auth needed while reference-free)
  • bats tests/extra-tmpl.bats β€” 3/3
  • CI green on all four platforms

πŸ€– Generated with Claude Code

hadees and others added 2 commits July 12, 2026 20:05
op inject parses the entire template β€” comments included β€” and errors
on any curly-brace pair or bare op:// text that isn't a real secret
reference. The template's self-documenting comments contained both, so
every render failed (including bootstrap's, which misreported it as an
auth failure). Instructions move to CLAUDE.md where literal syntax is
safe; the template keeps only a pointer and the parser warning.

Verified: `op inject -i .extra.tmpl` now renders cleanly, with no auth
needed while the template holds no references.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Guards the constraint that broke rendering: comment lines must never
contain brace pairs or op:// text, and any real reference must be
brace-wrapped with vault/item/field segments. Runs on CI without the
op CLI.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@hadees hadees self-assigned this Jul 13, 2026
@hadees
hadees merged commit 451efed into master Jul 13, 2026
4 checks passed
@hadees
hadees deleted the fix/extra-tmpl-op-inject branch July 13, 2026 01:09
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