Closed lmorchard closed 9 years ago
Yeah, I was actually looking at this sad, empty module earlier and thinking this would make sense.
I’m all for it and could do the grunt work later tonight :)
There's that option, or the option of having this module be a command line thing.
Or maybe that thing should be node-firefox-cli
? o_O
This one could certainly ship with a CLI as well? Like, npm install -g firefox
. node-firefox-cli
would be a weird CLI script to have to type all the time.
-tofumatt
On 26 March 2015 at 18:52:13, sole (notifications@github.com) wrote:
There's that option, or the option of having this module be a command line thing.
Or maybe that thing should be node-firefox-cli? o_O
— Reply to this email directly or view it on GitHub.
I believe when you install grunt-cli you don't type grunt-cli but grunt ;)
Yeah, but I loathe that. It’s like brew install mercurial
and you get the binary hg
. It’s super unexpected. :-(
you're actually right! and it's a thing that totally confused me with grunt. So let's not do this.
What about this - having this module do a module.exports but also importing and running the cli/binary if installed globally
That plan sounds perfect to me!
Going to call this done for now: https://github.com/mozilla/node-firefox/commit/4705b0daa3e315a4e398b6508c8b8480141cf898
But, I've also started working on a CLI tool: https://github.com/lmorchard/node-firefox-cli/tree/initial-implementation
What if node-firefox had an index.js like this?
Then, a developer could just include
node-firefox
in dependencies and usevar firefox = require('node-firefox');
to make calls likefirefox.findPorts()
. Or, even make shorter aliases likevar findPorts = firefox.findPorts
to cut down on redundantfirefox
es everywhere.