Skip to main content

Module shell

Module shell 

Source

Functions§

compress_if_beneficial_pub
Public wrapper for integration tests to exercise the compression pipeline.
decode_output
exec
exec_argv
Execute a command from pre-split argv without going through sh -c. Used by -t mode when the shell hook passes "$@" — arguments are already correctly split by the user’s shell, so re-serializing them into a string and re-parsing via sh -c would risk mangling complex quoted arguments (em-dashes, #, nested quotes, etc.).
interactive
is_container
Detects if the current process runs inside a Docker/container environment.
is_non_interactive
Returns true if stdin is NOT a terminal (pipe, /dev/null, etc.)
join_command
Join multiple CLI arguments into a single command string, using quoting conventions appropriate for the detected shell.
save_tee
shell_and_flag