Skip to content

Instantly share code, notes, and snippets.


Vladimir Grichina vgrichina

View GitHub Profile
catlan /
Last active Nov 9, 2020 — forked from zrxq/.lldbinit
Execute lldb command and open its output in Kaleidoscope diff

Diff output of two lldb commands


  1. Copy the contents of the last snippet (lldbinit) from the gist page, and paste into your .lldbinit file. This makes the ksdiff macro known inside lldb.
  2. Put file in ~/.lldb/
  3. sudo pip install temp
  4. Restart Xcode debug session


(lldb) ksdiff <any lldb command>; <any lldb command>

bishboria /
Last active Dec 18, 2020
Springer made a bunch of books available for free, these were the direct links
View gist:44b7063110fc423edb4d

Things that programmers don't know but should

(A book that I might eventually write!)

Gary Bernhardt

I imagine each of these chapters being about 2,000 words, making the whole book about the size of a small novel. For comparison, articles in large papers like the New York Times average about 1,200 words. Each topic gets whatever level of detail I can fit into that space. For simple topics, that's a lot of space: I can probably walk through a very basic, but working, implementation of the IP protocol.

syllog1sm / gist:10343947
Last active Nov 3, 2020
A simple Python dependency parser
View gist:10343947
"""A simple implementation of a greedy transition-based parser. Released under BSD license."""
from os import path
import os
import sys
from collections import defaultdict
import random
import time
import pickle
SHIFT = 0; RIGHT = 1; LEFT = 2;
lelandbatey /
Last active Jan 16, 2021
Whiteboard Picture Cleaner - Shell one-liner/script to clean up and beautify photos of whiteboards!


This simple script will take a picture of a whiteboard and use parts of the ImageMagick library with sane defaults to clean it up tremendously.

The script is here:

convert "$1" -morphology Convolve DoG:15,100,0 -negate -normalize -blur 0x1 -channel RBG -level 60%,91%,0.1 "$2"


debasishg / gist:8172796
Last active Jan 16, 2021
A collection of links for streaming algorithms and data structures
View gist:8172796
  1. General Background and Overview
lfzawacki /
Created Oct 31, 2013
Speeding up your BBB tests
while inotifywait -e modify $1; do
gradle --daemon test
plentz / nginx.conf
Last active Jan 18, 2021
Best nginx configuration for improved security(and performance). Complete blog post here
View nginx.conf
# to generate your dhparam.pem file, run in the terminal
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048
steipete / PSPDFUIKitMainThreadGuard.m
Last active Dec 11, 2020
This is a guard that tracks down UIKit access on threads other than main. This snippet is taken from the commercial iOS PDF framework, but relicensed under MIT. Works because a lot of calls internally call setNeedsDisplay or setNeedsLayout. Won't catch everything, but it's very lightweight and usually does the job.You might n…
View PSPDFUIKitMainThreadGuard.m
// Taken from the commercial iOS PDF framework
// Copyright (c) 2014 Peter Steinberger, PSPDFKit GmbH. All rights reserved.
// Licensed under MIT (
// You should only use this in debug builds. It doesn't use private API, but I wouldn't ship it.
// PLEASE DUPE rdar://27192338 ( if you would like to see this in UIKit.
#import <objc/runtime.h>
#import <objc/message.h>
markd2 / spy.d
Created May 17, 2013
Look at objective-C messages being sent in an application running in the simulator. "Interesting" symbols (configured in the first BEGIN block, or one provided on the command line) will get stack traces dumped. "ignored" symbols are not logged.
View spy.d
#!/usr/sbin/dtrace -s
/* Run like:
% sudo csh
Prints a line of dashes every 5 seconds to delineate different experiments.
#pragma D option quiet