All Projects → paulmillr → tag-shell

paulmillr / tag-shell

Licence: other
Use ES6 template tags for your node.js shell commands.

Programming Languages

javascript
184084 projects - #8 most used programming language

tag-shell

Use ES6 template tags for your node.js shell commands.

Using backticks is important and the package won't work otherwise.

const sh = require('tag-shell');
const opts = {app: 'App', icon: 'icon.png'};

// Async.
sh.async`notify-send -a ${opts.app}
  -i ${opts.icon}
`;

// Streaming.
sh.spawn`node -v`.stdout.on('data', data => console.log(data.toString()))

// Sync.
const version = sh`node -v`;

License

MIT

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].