visionmedia/commander.js — pull request #87 by focusaurus (2012-08-23 20:29:20+00:00)
Title: fix password on node 0.8.8. Make backward compatible with 0.6.

Node 0.8 does not emit keypress events for process.stdin anymore. Use TooTallNate's keypress module to emulate that. Maintain 0.6 compatibility falling back to tty.setRawMode.

Sadly, this introduces a dependent module, but on first glance keypress looks nontrivial to cherry-pick the bit we need for this.

Note test.prompt.js is failing is master as well, but the rest of the tests still pass on 0.8 and 0.6 with this change.