server.js 331 B

1234567891011121314
  1. /*
  2. * Simple connect server for phantom.js
  3. * Adapted from Modernizr
  4. */
  5. var connect = require('connect')
  6. , http = require('http')
  7. , fs = require('fs')
  8. , app = connect()
  9. .use(connect.static(__dirname + '/../../'));
  10. http.createServer(app).listen(3000);
  11. fs.writeFileSync(__dirname + '/pid.txt', process.pid, 'utf-8')