node.js : how to pipe - youtube to mp4 to mp3
Instead of passing the location of mp4 file, pass in the ytdl stream as the source, like so:
stream = ytdl(url)
proc = new ffmpeg({source:stream})
proc.setFfmpegPath('/Applications/ffmpeg')
proc.saveToFile(mp3, (stdout, stderr)->
return console.log stderr if err?
return console.log 'done'
)