policy: support commands with a value before a further subcommand, e.g. fj issue edit N title #52
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Commands that take a value and then a further subcommand cannot be called through wraptool. The first one hit is
fj issue edit <ISSUE> <title|body|comment|labels>.What happens
With an approved allow rule for
fj issue edit, the callfj_issue_edit(args: ["50", "body", "help"])fails:wraptool puts
--before positional arguments so they can never be read as flags. That is the right default, but it also stops a CLI from treating anything after the value as a subcommand. No policy change can makefj issue editwork today.A second obstacle
edit … bodyandedit … titlemost likely take the new text as a positional argument. The argument sanitizer rejects backticks and parentheses, so Markdown cannot go through even once the--problem is solved.fj issue createandfj pr createget around this with--body-file; check whetheredithas an equivalent.Possible directions
["issue", "edit", "*", "title"], where*matches one constrained positional (type and shape checked) and--goes after the whole path.design/free-text-sanitization-tier.md.Done when
fj issue edit <N> title <text>works under an allow rule with a placeholder, the placeholder is validated, flag injection stays impossible, and there are tests for the argv wraptool builds.🤖 Generated with Claude Code