lute

Sat Jul 12 2014 18:59:27 GMT+0100 (British Summer Time)

I found this little development server built with node.js and I thought I'd recommend it to you since it fixes most of the annoyances I have with the traditional SimpleHTTPServer Python solution. You can install it globally with:

npm install -g lute

And then you can enjoy...

1) Automatic port management

It will find a new available port if the default is in use, so you don't have to manually manage this, which can be cumbersome when you need to have several local servers running at the same time. Just type

lute

and TA-DA! you get a local server with autoassigned port, serving the files in the current directory.

Or you can also force it to use an specific port:

lute -p 3030

2) It can trigger the 'open' action in your browser

You can write this on your command line

lute open

and it will open localhost at whatever port it found, using your default browser.

3) Automatically injects livereload in your scripts

This can be both a blessing and an annoyance--it is not playing too well with HTML imports:

A call to document.write() from an asynchronously-loaded external script was ignored.