-
-
Save masylum/1723725 to your computer and use it in GitHub Desktop.
Super simple node file server
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require('http').Server(function (req, res) { | |
require('fs').createReadStream(__dirname + require('url').parse(req.url).pathname).pipe(res); | |
}).listen(9000); |
txus
commented
Feb 2, 2012
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment