Possible Duplicate:
How to use nodejs to open default browser and navigate to a specific URL
I don't know if it matters, but I am on OSX.
I know you can launch a browser from the command line itself by typing:
open http://www.stackoverflow.com
But is there a way to open a browser from inside a nodejs command line script?
Use opn because it will handle the cross platform issue. To install:
$ npm install opn
To use:
var opn = require('opn');
// opens the url in the default browser
opn('http://sindresorhus.com');
// specify the app to open in
opn('http://sindresorhus.com', {app: 'firefox'});