Compare commits

...

1 Commits

Author SHA1 Message Date
Mauricio Siu
fcec9d43a6 docs: trim block comment on shellWord helper 2026-07-19 21:36:25 -06:00

View File

@@ -1,10 +1,6 @@
import { quote } from "shell-quote"; import { quote } from "shell-quote";
/** // Escapes a value so it is safe to interpolate as a single argument into a
* Escapes a single value so it can be safely interpolated as one argument into // /bin/sh -c command string (local execAsync and remote SSH execAsyncRemote).
* a `/bin/sh -c` command string (both local `execAsync` and remote SSH
* `execAsyncRemote`). User-controlled fields such as git URLs, branch names,
* repository owners and SSH hostnames must never reach a shell unescaped.
*/
export const shellWord = (value: string | number | null | undefined): string => export const shellWord = (value: string | number | null | undefined): string =>
quote([String(value ?? "")]); quote([String(value ?? "")]);