node-child-process-args:使用自检转义node.js的shell参数

用法: var spawn = require ( 'child_process' ) . spawn ; var childProcessArgs = require ( 'child-process-args' ) ; childProcessArgs ( [ 'rsync' , '-aHC' , 'root@machine2:/remotePath' , './Local Path' , '--exclude' , '/Exclude me/' ] ) . then ( function ( rsyncCommand ) { var child = spawn ( 'ssh' , [ 'root@machine1' , rsyncCommand ] , { stdio : 'inherit' } ) ;
zip 文件大小:3.37KB