Skip to content

Instantly share code, notes, and snippets.

View lavalake's full-sized avatar

jian wang lavalake

View GitHub Profile
@lavalake
lavalake / introrx.md
Created December 14, 2017 21:03 — forked from staltz/introrx.md
The introduction to Reactive Programming you've been missing
@lavalake
lavalake / gist:d83a5bc14284161433019475013996d1
Created October 14, 2017 01:54 — forked from tsohr/gist:5711945
Android activity manager "am" command help
adb shell am
usage: am [subcommand] [options]
usage: am start [-D] [-W] [-P <FILE>] [--start-profiler <FILE>]
[--R COUNT] [-S] [--opengl-trace] <INTENT>
am startservice <INTENT>
am force-stop <PACKAGE>
am kill <PACKAGE>
am kill-all
am broadcast <INTENT>
am instrument [-r] [-e <NAME> <VALUE>] [-p <FILE>] [-w]
@lavalake
lavalake / tmux.md
Created January 5, 2017 22:33 — forked from andreyvit/tmux.md
tmux cheatsheet

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

@lavalake
lavalake / tmux-cheatsheet.markdown
Created December 29, 2016 18:15 — forked from MohamedAlaa/tmux-cheatsheet.markdown
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@lavalake
lavalake / iterm2-solarized.md
Created December 9, 2016 21:47 — forked from kevin-smets/iterm2-solarized.md
iTerm2 + Oh My Zsh + Solarized color scheme + Meslo powerline font (OS X / macOS)

Solarized

@lavalake
lavalake / sysctl.conf
Created June 16, 2016 04:56 — forked from kgriffs/sysctl.conf
Linux Web Server Kernel Tuning
# Configuration file for runtime kernel parameters.
# See sysctl.conf(5) for more information.
# See also http://www.nateware.com/linux-network-tuning-for-2013.html for
# an explanation about some of these parameters, and instructions for
# a few other tweaks outside this file.
# Protection from SYN flood attack.
net.ipv4.tcp_syncookies = 1
@lavalake
lavalake / hash.c
Created November 1, 2015 18:41 — forked from tonious/hash.c
A quick hashtable implementation in c.
#define _XOPEN_SOURCE 500 /* Enable certain library functions (strdup) on linux. See feature_test_macros(7) */
#include <stdlib.h>
#include <stdio.h>
#include <limits.h>
#include <string.h>
struct entry_s {
char *key;
char *value;