{"name":"escape-string-applescript","version":"0.1.0","description":"Escape a string for use in AppleScript","license":"MIT","repository":{"type":"git","url":"git://github.com/sindresorhus/escape-string-applescript"},"author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"http://sindresorhus.com"},"engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"files":["index.js"],"keywords":["escape","string","str","applescript","osascript","quote","quotes","backslash"],"devDependencies":{"mocha":"*"},"bugs":{"url":"https://github.com/sindresorhus/escape-string-applescript/issues"},"homepage":"https://github.com/sindresorhus/escape-string-applescript","_id":"escape-string-applescript@0.1.0","_shasum":"861190ae8948081d7a905fb82b076bd6776827a4","_from":".","_npmVersion":"1.4.9","_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"dist":{"shasum":"861190ae8948081d7a905fb82b076bd6776827a4","tarball":"http://registry-npm.ywwl.com/escape-string-applescript/download/escape-string-applescript-0.1.0.tgz","integrity":"sha512-rQImC9pmFWUUl+OHB427AHKy5B7h05tzKb1F1/7AZDx1Udo6BCKNGARnLH8z2Kf27WV3N/KL4pXdC0yWjth/ZQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDUSy8+0ZTLWICBtRLKhxQn9Z43PSZE254exIgzFUj4yQIgYu13duvGG+ZqmPtwHbjFxoJSH7J8Czb5xyU/eqJtQOE="}],"size":966,"noattachment":false,"key":"/escape-string-applescript/-/escape-string-applescript-0.1.0.tgz"},"directories":{},"readme":"# escape-string-applescript\n\n> Escape a string for use in AppleScript\n\nAccording to the AppleScript [docs](https://developer.apple.com/library/mac/documentation/AppleScript/Conceptual/AppleScriptLangGuide/reference/ASLR_classes.html#//apple_ref/doc/uid/TP40000983-CH1g-DontLinkElementID_57), `\\` and `\"` have special meaning and should be escaped.\n\n## Install\n\n```\n$ npm install escape-string-applescript\n```\n\n## Usage\n\n```js\nimport {execFile} from 'child_process';\nimport escapeStringAppleScript from 'escape-string-applescript';\n\nconst string = escapeStringAppleScript('\"i like unicorns\"');\n//=> '\\\"i like unicorns\\\"'\n\nconst script = `set unicornMessage to \"${string}\"`;\n\nexecFile('osascript', ['-e', script]);\n```\n\n## Related\n\n- [run-applescript](https://github.com/sindresorhus/run-applescript) - Run AppleScript and get the result\n","publish_time":1400108864318,"_cnpm_publish_time":1400108864318,"dist-tags":{"latest":"3.0.0"}}