npm install vlc-command
var cp = require('child_process')
var vlcCommand = require('vlc-command')
vlcCommand(function (err, cmd) {
if (err) return console.error('could not find vlc command path')
if (process.platform === 'win32') {
cp.execFile(cmd, ['--version'], function (err, stdout) {
if (err) return console.error(err)
console.log(stdout)
})
} else {
cp.exec(cmd + ' --version', function (err, stdout) {
if (err) return console.error(err)
console.log(stdout)
})
}
})
MIT. Copyright (c) Feross Aboukhadijeh.