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
var http = require('http'), | |
net = require('net'); | |
try { | |
var req = http.request({ | |
host: '127.0.0.1', | |
port: 18602, | |
'createConnection': | |
function (port, host) { | |
var s = new net.Socket(); |
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
Username for 'https://github.com': myndzi | |
Password for 'https://[email protected]': | |
Counting objects: 553, done. | |
Delta compression using up to 16 threads. | |
fatal: unable to create thread: Resource temporarily unavailable | |
fatal: The remote end hung up unexpectedly | |
fatal: The remote end hung up unexpectedly | |
fatal: write error: Bad file descriptor |
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
// ==ClosureCompiler== | |
// @compilation_level ADVANCED_OPTIMIZATIONS | |
// @output_file_name default.js | |
// ==/ClosureCompiler== | |
// ADD YOUR CODE HERE | |
(function ($) { | |
/** | |
* Augment jQuery prototype. | |
*/ |
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
var f=null,k=!1; | |
(function(b){function l(a,e){this.b=b(a);this.e=e||{};this.g=k!==this.e.x||this.e.forceHorizontal;this.h=k!==this.e.y||this.e.forceVertical;this.i=k!==this.e.autoHide;this.f=void 0==this.e.padding?2:this.e.padding;this.a=this.b.find(".antiscroll-inner");this.a.css({width:"+="+(this.h?g():0),height:"+="+(this.g?g():0)});var d={};this.g&&(d.width="+="+g());this.h&&(d.height="+="+g());this.a.css(d);this.k()}function c(a){this.a=a;this.a.b.append(this.b);this.c=this.a.a.get(0);this.d=this.f=this.e=k; | |
this.a.b.mouseenter(b.proxy(this,"z"));this.a.b.mouseleave(b.proxy(this,"y"));this.b.mousedown(b.proxy(this,"x"));this.l=b.proxy(this,"u");this.a.a.scroll(this.l);this.k=b.proxy(this,"w");this.a.a.bind("mousewheel",this.k);a=this.a.e.initialDisplay;a!==k&&(this.h(),this.a.i&&(this.g=setTimeout(b.proxy(this,"hide"),parseInt(a,10)||3E3)))}function n(a,e){function d(){}d.prototype=e.prototype;a.prototype=new d}function g(){if(void 0===m){var a=b('<div class="antiscroll-inner" style="width:50px;height:50 |
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
Friend.findOne({ | |
userId: req.signedCookies.userid | |
}, function (err, signedInUser) { | |
var friends = signedInUser.friends.map( | |
function (a) { return { user: a, type: 'friend' }; } | |
), | |
sentRequests = signedInUser.request_sent_to.map( | |
function (a) { return { user: a, type: 'sent' }; } | |
), |
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
* In 'funcs.js': | |
module.exports = { | |
generatePseudoRandomToken: generatePseudoRandomToken, | |
cookieWatcher: cookieWatcher | |
}; | |
function generatePseudoRandomToken() { | |
require('crypto').randomBytes(48, function(ex, buf) { | |
var token = buf.toString('hex'); | |
}); |
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
var api = require('socket.io') | |
, io = null; | |
var Message = require('./message') | |
, User = require('./user'); | |
var waitDelay = 1 | |
, linePenalty = 2 | |
, burstThreshold = 10 | |
, numCharsPenalty = 120 |
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
#include <v8.h> | |
#include <node.h> | |
#include <node_buffer.h> | |
#include <node_version.h> | |
#include <unistd.h> | |
#include <string> | |
#include <map> | |
#include <exception> | |
#include <exiv2/image.hpp> | |
#include <exiv2/exif.hpp> |
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
function circle(buffer, cx, cy, radius) { | |
var error = -radius, | |
x = radius, | |
y = 0, | |
lastY; | |
while (x >= y) { | |
lastY = y; | |
error += y; |
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
Setup: | |
// (actually this is module.exports) | |
var Prompt = new Blackbird(function (Promise) { | |
function Prompt(opts, ctx) { | |
this._opts = opts || { }; | |
// copy over initialization variables | |
ctx = ctx || { }; | |
for (var key in ctx) { | |
if (ctx.hasOwnProperty(key)) { |
OlderNewer