(step: NextStep)
| 10 | const SHELL_SAFE_UNQUOTED_ARG = /^[A-Za-z0-9_@%+=:,./~-]+$/; |
| 11 | |
| 12 | function resolveLabel(step: NextStep): string { |
| 13 | const label = step.label?.trim(); |
| 14 | if (label) return label; |
| 15 | if (step.tool) return step.tool; |
| 16 | if (step.cliTool) return step.cliTool; |
| 17 | return 'Next action'; |
| 18 | } |
| 19 | |
| 20 | function formatCliArg(value: string): string { |
| 21 | return SHELL_SAFE_UNQUOTED_ARG.test(value) && !value.startsWith('-') |
no outgoing calls
no test coverage detected