query
On this page

escapeShellArgs

lib.escapeShellArgs

Docs pulled from | This Revision | about 1 hour ago


Nixpkgs manual

Quote all arguments that have special characters to be safely passed to the Bourne shell.

Inputs

args
1. Function argument

Type

escapeShellArgs :: [String] -> String

Examples

lib.strings.escapeShellArgs usage example

escapeShellArgs ["one" "two three" "four'five"]
=> "one 'two three' 'four'\\''five'"
(lib.strings.escapeShellArgs)

Noogle detected

Aliases

Implementation

The following is the current implementation of this function.

list:
    concatStringsSep sep (map f list)