Skip to content

Instantly share code, notes, and snippets.

@dsummersl
dsummersl / keybase.md
Created April 15, 2015 04:15
keybase.md

Keybase proof

I hereby claim:

  • I am dsummersl on github.
  • I am ntx3holc (https://keybase.io/ntx3holc) on keybase.
  • I have a public key whose fingerprint is 30D7 EB1C 3C2A B919 3036 B2E3 2834 CC62 9693 E1BD

To claim this, I am signing this object:

2015-04-02_20:15:54.15087 #
2015-04-02_20:15:54.15088 # Fatal error in a, line 11
2015-04-02_20:15:54.15089 # c
2015-04-02_20:15:54.15089 #
2015-04-02_20:15:54.15090
2015-04-02_20:15:54.15153 {"name":"flurry","hostname":"ip-172-31-29-187","pid":7838,"level":30,"headers":{"host":"mobile.btrll.com","content-type":"application/json","user-agent":"Apache-HttpAsyncClient/4.0-beta4 (java 1.5)","x-openrtb-version":"2.1","x-forwarded-for":"216.52.203.134","x-forwarded-port":"80","x-forwarded-proto":"http","content-length":"1937","connection":"keep-alive"},"url":"/ad?integration=flurry","POST":{"id":"7bcd7068-08d5-4c63-a723-8f822b336b53","imp":[{"id":"1fc563cb-b6f6-4ec2-8cf8-b3e2863328d3","banner":{"w":480,"h":320,"ext":{"rewarded":0,"video":{"mimes":["video/mp4"],"linearity":1,"minduration":1,"maxduration":30,"minbitrate":0,"maxbitrate":500,"protocol":[1,2,3],"w":320,"h":480,"ext":{"rewarded":1,"video_skippable":"BLOCK_SKIPPABLE","skip_offset":30,"ad_group_id":"flurry_in_network"},"playbackmethod":[1]}},"pos":0,"bt
x27[?25lx27[1Fx27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;0m x27[48;5;22m x27[48;5;64m x27[48;5;64m x27[48;5;2m x27[48;5;76m x27[48;5;76m x27[48;5;76m x27[48;5;76m x27[48;5;2m x27[48;5;64m x27[48;5;28m x27[48;5;22m x27[48;5;22m x27[48;5;64m x27[48;5;28m x27[48;5;34m x27[48;5;28m x27[48;5;64m x27[48;5;34m x27[48;5;64m x27[48;5;28m x27[48;5;28m x27[48;5;64m x27[48;5;34m x27[48;5;64m x27[48;5;64m x27[48;5;64m x27[48;5;64m x27[48;5;22m x27[48;5;22m x27[48;5;22m x27[48;5;22m x27[48;5;0m x27[48;5;22m x27[48;5;0m x27[48;5;0m x27[48;5;22m x27[48;5;0m x27[48
for (line, logstr) in zip(lines, text):
line = "".join(line)
if len(line.strip()) == 0: continue
result.append(["%-*s" % (2 * indentation_level, line), logstr])
readFile("some/file.txt").then(function(stream) {
stream
.pipe(es.split('\n'))
.map(function(data) { return data.substring(5); });
});
──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
var dns = require("dns");
var count = 0;
var gotResponse = true;
setInterval(function () {
var cnt = ++count;
if (gotResponse) {
gotResponse = false;
console.time("dnslookup"+ cnt);
var express = require("express");
var app = express();
app.use(function(req, res, next) {
setTimeout(function() {
console.log("("+ process.pid +"): "+ new Date() +" XXX");
res.end("X");
},5000);
console.log("("+ process.pid +"): "+ new Date() +" handles="+ process._getActiveHandles().length +" requests="+ process._getActiveRequests().length);
});
@dsummersl
dsummersl / gist:2b9faa9133322c33b465
Created November 24, 2014 19:04
:bda command to clear out hidden buffers
" delete all buffers function
function! DeleteHiddenBuffers()
let tpbl=[]
call map(range(1, tabpagenr('$')), 'extend(tpbl, tabpagebuflist(v:val))')
for buf in filter(range(1, bufnr('$')), 'bufexists(v:val) && index(tpbl, v:val)==-1')
silent execute 'bwipeout' buf
endfor
endfunction
cabbrev bda call DeleteHiddenBuffers()
@dsummersl
dsummersl / gist:11085439
Created April 19, 2014 14:10
.env.openshift
# ==== Required configuration settings for Huginn ====
# Replace the following with the output from "rake secret"
# (unnecessary, since we'll be using the OpenShift-provided secret)
# APP_SECRET_TOKEN=REPLACE_ME_NOW!
# This is the domain where your Huginn instance will be running. The default should work
# for development, but it needs to be changed to your Huginn domain when you deploy to a
# production environment (e.g., yourdomain.com, possibly including a port).
DOMAIN=$OPENSHIFT_APP_DNS
@dsummersl
dsummersl / gist:10403425
Created April 10, 2014 17:15
3 lines: space, tab, space
space
tab
space