Skip to content

Instantly share code, notes, and snippets.

View danShumway's full-sized avatar

Daniel Shumway danShumway

View GitHub Profile
var http = require("http"),
url = require("url"),
path = require("path"),
fs = require("fs")
port = process.argv[2] || 8888;
http.createServer(function(request, response) {
var uri = url.parse(request.url).pathname
, filename = path.join(process.cwd(), uri);