Skip to content

Instantly share code, notes, and snippets.

imjasonh / markdown.css
Last active Jun 10, 2021
Render Markdown as unrendered Markdown (see
View markdown.css
* {
font-size: 12pt;
font-family: monospace;
font-weight: normal;
font-style: normal;
text-decoration: none;
color: black;
cursor: default;
View gist:598fa75e22bdfa44cf47

2015-01-29 Unofficial Relay FAQ

Compilation of questions and answers about Relay from React.js Conf.

Disclaimer: I work on Relay at Facebook. Relay is a complex system on which we're iterating aggressively. I'll do my best here to provide accurate, useful answers, but the details are subject to change. I may also be wrong. Feedback and additional questions are welcome.

What is Relay?

Relay is a new framework from Facebook that provides data-fetching functionality for React applications. It was announced at React.js Conf (January 2015).

andremedeiros /
Last active Aug 29, 2015
Baruco 2014 talks

Baruco 2014 talks

Please see the Hackpad where we can all contribute!

tiegz / object_profiler.rb
Last active Aug 29, 2015
Object Profiler for ruby 2.1.0+
View object_profiler.rb
module ObjectSpace
def self.profile(&blk)
require 'objspace'
enable_gc = GC.disable
objs =
ObjectSpace.each_object { |o|
if (file = ObjectSpace.allocation_sourcefile(o)) && (line = ObjectSpace.allocation_sourceline(o))
objs["#{file}:#{line}:#{}"] += 1
knyar / statsd.lua
Created Feb 9, 2014
statsd interface for nginx (via ngx_lua)
View statsd.lua
-- ----------------------------------------------------------------------------
-- statsd interface for nginx
-- (c) 2014 Anton Tolchanov
-- Usage:
-- 1. install nginx with ngx_lua;
-- 2. put this file as statsd.lua somewhere (/var/lib/nginx/lua/ will do);
-- 3. initialize stats in init_by_lua:
-- http {
hubert3 /
Last active Dec 15, 2016
Python implementation of passcode hashing algorithm used on the Samsung Galaxy S4 GT-I9505 4.2.2
Python implementation of passcode hashing algorithm used on the Samsung Galaxy S4 GT-I9505 4.2.2
Correct PIN for hash and salt below is 1234.
Get 40-character hash value in ascii hex format from file /data/system/password.key on the phone
Get salt in signed numeric format by doing sqlite3 query SELECT value FROM locksettings WHERE name = 'lockscreen.password_salt' on /data/system/locksettings.db
View gist:8393897
Ruby 2.1.0 in Production: known bugs and patches
Last week, we upgraded the rails app to ruby 2.1.0 in production.
While testing the new build for rollout, we ran into a number of bugs. Most of
these have been fixed on trunk already, but I've documented them below to help
anyone else who might be testing ruby 2.1 in production.
@naruse I think we should backport these patches to the ruby_2_1 branch and
release 2.1.1 sooner rather than later, as some of the bugs are quite critical.
I'm happy to offer any assistance I can to expedite this process.
chengyin / linkedout.js
Last active Oct 2, 2020
Unsubscribe all LinkedIn email in "one click". For an easier to use version, you can check out the bookmarklet:
View linkedout.js
// 1. Go to page
// 2. You may need to login
// 3. Open JS console
// ([How to?](
// 4. Copy the following code in and execute
// 5. No more emails
// Bookmarklet version:
sxua /
Created Sep 18, 2013
UIAppearance methods (including iOS 7)



@property (readwrite, nonatomic, retain) UIColor *color


aienn / bydloscript.rb
Created Mar 11, 2013
View bydloscript.rb
#usage ruby bydloscript.rb Здесь смешные надписи кириллицей лол!
source = ARGV.join(" ").strip.split(//)
table = { "а" => "a", "А" => "A",
"б" => "6", "Б" => "6",
"в" => "B", "В" => "B",
"г" => "r", "Г" => "r",
"д" => "D", "Д" => "D",
"е" => "e", "Е" => "E",
"ё" => "e", "Ё" => "E",