layout: post title: "Ender Roundup: tablesort.js, Moment.js, jwerty, SelectNav.js, ender-events, ender-assert, Categorizr.js, Arbiter" author: Rod Vagg categories:
- ender
- frameworks
- modules
- libraries
- time
/** Dependency: 'colors', `npm install colors` first **/ | |
/** | |
* | |
* This file demonstrates some broken parts of NPM's API, in particular the use of | |
* outfd and logfd options. This module will span 4 child processes to run NPM via | |
* its API, first for npm.commands.search and then for npm.commands.install. The 4 | |
* child processes use different outfd & logfd options: | |
* (1) stdout (i.e. `1`) | |
* (2) an actual file descriptor |
layout: post title: "Ender Roundup: tablesort.js, Moment.js, jwerty, SelectNav.js, ender-events, ender-assert, Categorizr.js, Arbiter" author: Rod Vagg categories:
function getTempImg(base64Image, filename, callback) { | |
var decodedImage = new Buffer(base64Image, 'base64'); | |
var filename = 'cache/' + filename + '.jpg'; | |
fs.writeFile(filename, decodedImage, function(err, data) { | |
console.log(data); | |
if (err) return callback(err); | |
callback(null, filename); | |
}) | |
} |
DamonOehlman: Brisbane, Australia | |
cliffano: Melbourne, Australia | |
unnali: Melbourne, Australia | |
samcday: Brisbane, Australia | |
chriso: Sydney, Australia | |
z0w0: Australia | |
morganrallen: Sydney, Australia | |
anthonyshort: Newcastle, Australia | |
balupton: Sydney, Australia | |
deoxxa: Melbourne, Australia |
{ | |
"_id": "_design/app", | |
"_rev": "607-6efd9a48552b62b0e2f52b1851589ea2", | |
"views": { | |
"updated": { | |
"map": "function (doc) {\n var l = doc[\"dist-tags\"].latest\n , t = doc.time && doc.time[l]\n if (t) emit(t, 1)\n}" | |
}, | |
"listAll": { | |
"map": "function (doc) { return emit(doc._id, doc) }" | |
}, |
{ | |
"predef": [ "assert", "refute", "define" ] | |
, "boss": true | |
, "bitwise": true | |
, "shadow": true | |
, "trailing": true | |
, "immed": true | |
, "latedef": true | |
, "forin": false | |
, "curly": false |
Location = { | |
referencia: { | |
type: Number, | |
unique: true | |
}, | |
owner: { | |
type: Schema.Types.ObjectId, | |
ref: 'Owner' | |
}, | |
accounts: [ |
Node master, 4 core CPU with plenty of RAM.
$ make clean >& /dev/null; ./configure >& /dev/null ; date; make -j 4 >& /dev/null; date; make clean >& /dev/null; ./configure >& /dev/null; date; make -j 25 >& /dev/null; date
Mon Feb 11 11:21:11 EST 2013
Mon Feb 11 11:22:58 EST 2013
Mon Feb 11 11:22:59 EST 2013
Mon Feb 11 11:24:23 EST 2013
var http = require('http') | |
http.createServer(function (req, res) { | |
console.log('Original Headers:', req.socket._originalHeaders) | |
console.log('Messed up Headers:', req.headers) | |
res.end('BINGO') | |
}) | |
.on('connection', function (socket) { | |
if (!socket.parser._onHeadersComplete) | |
socket.parser._onHeadersComplete = socket.parser.onHeadersComplete |
Work in progress, I'll write this up properly when I'm done.
Almost all credit goes to @maxogden for putting me on to this and pointing me in the right direction for each of these items.
Prerequisites: