Skip to content

feat(snippet): add {{n}} placeholder support for parameterized snippets#17

Merged
ffgenius merged 1 commit into
masterfrom
feat/snippet-placeholders
Jul 7, 2026
Merged

feat(snippet): add {{n}} placeholder support for parameterized snippets#17
ffgenius merged 1 commit into
masterfrom
feat/snippet-placeholders

Conversation

@ffgenius

@ffgenius ffgenius commented Jul 7, 2026

Copy link
Copy Markdown
Owner

Snippet content can now contain {{0}}, {{1}}, … placeholders that are substituted with positional arguments at runtime:

relay snippet add killport --shell powershell 'Get-NetTCPConnection -LocalPort {{0}} | ForEach-Object { … }'
relay snippet run killport 4600
killport 4600 # shim forwarding works too

If a placeholder index exceeds the number of args provided, relay returns a clear error (MissingPlaceholderArg).

Snippet content can now contain {{0}}, {{1}}, … placeholders that are
substituted with positional arguments at runtime:

  relay snippet add killport --shell powershell     'Get-NetTCPConnection -LocalPort {{0}} | ForEach-Object { … }'
  relay snippet run killport 4600
  killport 4600     # shim forwarding works too

If a placeholder index exceeds the number of args provided, relay
returns a clear error (MissingPlaceholderArg).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@ffgenius ffgenius merged commit bc6da29 into master Jul 7, 2026
4 checks passed
@ffgenius ffgenius deleted the feat/snippet-placeholders branch July 7, 2026 07:55
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