GT2/GT2-iOS/node_modules/clipboardy/lib/macos.js

12 lines
418 B
JavaScript
Raw Normal View History

2018-02-12 17:26:06 +00:00
'use strct';
const execa = require('execa');
const env = Object.assign({}, process.env, {LC_CTYPE: 'UTF-8'});
module.exports = {
copy: opts => execa('pbcopy', Object.assign({}, opts, {env})),
paste: opts => execa.stdout('pbpaste', Object.assign({}, opts, {env})),
copySync: opts => execa.sync('pbcopy', Object.assign({}, opts, {env})),
pasteSync: opts => execa.sync('pbpaste', Object.assign({}, opts, {env}))
};