shlex
Shell quoting and string splitting utilities.
Functions
quote obj
Quote a string for shell safety.
Parameters:
| Name | Type | Description |
|---|---|---|
obj |
value to quote (converted with std.arg |
Returns: str - The quoted string.
split string
Split a shell-quoted string into tokens, returning an iterator.
Parameters:
| Name | Type | Description |
|---|---|---|
string |
str |
string to split |
Returns: Iter yielding each argument.
join iterable
Join an iterable of arguments into a shell-quoted string.
Parameters:
| Name | Type | Description |
|---|---|---|
iterable |
iterable of values (converted with std.arg) |
Returns: str - Joined string with proper quoting.