Skip to content

Instantly share code, notes, and snippets.

@cmisenas
cmisenas / human.md
Created October 14, 2021 20:23 — forked from cassidoo/human.md
Human Template for Obsidian
cuid alias tags
human<% tp.file.creation_date("YYYYMMDD-HHmmss") %>
👤 <% tp.file.title.substring(1) %>
<% tp.file.title.substring(1) %>
person/friends, person/family, person/coworker, person/rwc

👤 <% tp.file.title.substring(1) %>

🎂 Birthday: 💌 Email: ☎️ Phone:

@cmisenas
cmisenas / papers.md
Created July 30, 2018 05:23 — forked from jhertz/papers.md
Security Papers I Like

In absolutely no order

@cmisenas
cmisenas / jessfraz.md
Created July 30, 2018 05:07 — forked from acolyer/jessfraz.md
Containers, operating systems and other fun things from The Morning Paper
@cmisenas
cmisenas / latency.txt
Created November 5, 2017 18:07 — forked from jboner/latency.txt
Latency Numbers Every Programmer Should Know
Latency Comparison Numbers
--------------------------
L1 cache reference 0.5 ns
Branch mispredict 5 ns
L2 cache reference 7 ns 14x L1 cache
Mutex lock/unlock 25 ns
Main memory reference 100 ns 20x L2 cache, 200x L1 cache
Compress 1K bytes with Zippy 3,000 ns 3 us
Send 1K bytes over 1 Gbps network 10,000 ns 10 us
Read 4K randomly from SSD* 150,000 ns 150 us ~1GB/sec SSD
@cmisenas
cmisenas / latency.markdown
Created October 13, 2016 16:15 — forked from hellerbarde/latency.markdown
Latency numbers every programmer should know

Latency numbers every programmer should know

L1 cache reference ......................... 0.5 ns
Branch mispredict ............................ 5 ns
L2 cache reference ........................... 7 ns
Mutex lock/unlock ........................... 25 ns
Main memory reference ...................... 100 ns             
Compress 1K bytes with Zippy ............. 3,000 ns  =   3 µs
Send 2K bytes over 1 Gbps network ....... 20,000 ns  =  20 µs
SSD random read ........................ 150,000 ns  = 150 µs

Read 1 MB sequentially from memory ..... 250,000 ns = 250 µs

@cmisenas
cmisenas / gist:5ca1195e6d467d6876ce
Created November 18, 2015 16:33 — forked from nicholasbs/gist:3327493
A (very) quick introduction to garbage collection
// When you create a new object
var obj = {data: "some data here"};
/* The JavaScript runtime environment allocates memory for you.
__________________________
Your computer's memory ----> || Location || Value ||
||------------------------||
It has to store that obj is || 0 || 2424 ||
an object, that it has a || 1 || 1002 ||
property named data, and || 2 || 327871 ||
@cmisenas
cmisenas / about.md
Last active August 29, 2015 14:25 — forked from jasonrudolph/about.md
@cmisenas
cmisenas / tmux.md
Last active August 29, 2015 14:24 — forked from andreyvit/tmux.md

tmux cheat sheet

(C-x means ctrl+x, M-x means alt+x)

Prefix key

The default prefix is C-b. If you (or your muscle memory) prefer C-a, you need to add this to ~/.tmux.conf:

remap prefix to Control + a

=Navigating=
visit('/projects')
visit(post_comments_path(post))
=Clicking links and buttons=
click_link('id-of-link')
click_link('Link Text')
click_button('Save')
click('Link Text') # Click either a link or a button
click('Button Value')
We first want to take a look at what versions are installed for a given formula, `brew info FORMULA`. Let's take a look at the versions of Redis that are installed.
```
@czq. ➜ Formula rvm:() git:(master) brew info redis
redis 2.4.5
http://redis.io/
/usr/local/Cellar/redis/2.4.4 (9 files, 460K)
/usr/local/Cellar/redis/2.4.5 (9 files, 460K) *
...
```