nyc-bookstores/node_modules/browserify/node_modules/shell-quote
2013-05-27 13:45:59 -07:00
..
example all da files 2013-05-27 13:45:59 -07:00
test all da files 2013-05-27 13:45:59 -07:00
.travis.yml all da files 2013-05-27 13:45:59 -07:00
index.js all da files 2013-05-27 13:45:59 -07:00
package.json all da files 2013-05-27 13:45:59 -07:00
README.markdown all da files 2013-05-27 13:45:59 -07:00

shell-quote

Parse and quote shell commands.

build status

example

quote

var quote = require('shell-quote').quote;
var s = quote([ 'a', 'b c d', '$f', '"g"' ]);
console.log(s);

output

a 'b c d' \$f '"g"'

parse

``` js` var parse = require('shell-quote').parse; var xs = parse('a "b c" \$def 'it\'s great''); console.dir(xs);


output

[ 'a', 'b c', '\$def', 'it's great' ]


methods
=======

``` js
var quote = require('shell-quote').quote;
var parse = require('shell-quote').parse;

quote(args)

Return a quoted string for the array args suitable for using in shell commands.

parse(cmd)

Return an array of arguments from the quoted string cmd.

install

With npm do:

npm install shell-quote

license

MIT