Persist a node repl's history to a file.
install: npm install repl.local.history
var repl = require('repl').start('> ');
require('repl.local.history')(repl, process.cwd() + '/.node_history');this will drop a .node_history file in your current working directory. Useful for when working on multiple projects without wanting to clutter your history.
install: npm install -g repl.local.history
run repl.local.history on the command line
A file .node_history will be created.
I like to alias it to nr for node repl