Initial commit

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
dinlo
2026-05-31 18:45:31 +08:00
commit e0a986eb30
1018 changed files with 615974 additions and 0 deletions
+19
View File
@@ -0,0 +1,19 @@
var shellescape = require('../');
var assert = require('assert');
var d = {
"echo 'hello\\nworld'": ['echo', 'hello\\nworld'],
"echo 'hello\\tworld'": ['echo', 'hello\\tworld'],
"echo '\thello\nworld'\\'": ['echo', '\thello\nworld\''],
"echo 'hello world'": ['echo', 'hello world'],
"echo hello world": ['echo', 'hello', 'world'],
"echo 'hello\\\\'\\' \\''\\\\'\\''world'": ["echo", "hello\\\\'", "'\\\\'world"],
"echo hello 'world\\'": ["echo", "hello", "world\\"]
};
Object.keys(d).forEach(function(s) {
var escaped = shellescape(d[s]);
assert.strictEqual(escaped, s);
console.log(s);
});