MCPcopy Create free account
hub / github.com/browserbase/stagehand / tokenizeArgv

Function tokenizeArgv

packages/evals/tui/commandTree.ts:691–704  ·  view source on GitHub ↗
(args: readonly string[])

Source from the content-addressed store, hash-verified

689 * or option values legitimately contain `>` characters.
690 */
691export function tokenizeArgv(args: readonly string[]): string[] {
692 const out: string[] = [];
693 for (const arg of args) {
694 if (arg === ">") continue;
695 if (!arg.includes(">")) {
696 out.push(arg);
697 continue;
698 }
699 for (const piece of arg.split(">")) {
700 if (piece) out.push(piece);
701 }
702 }
703 return out;
704}
705
706// Re-export tokenize so callers only import from one place.
707export { tokenize };

Callers 2

cli.tsFile · 0.85

Calls 2

includesMethod · 0.80
splitMethod · 0.80

Tested by

no test coverage detected