Skip to content

Instantly share code, notes, and snippets.

Hiring chip architect at NVIDIA Shanghai office.

Max Lv madeye

Hiring chip architect at NVIDIA Shanghai office.
View GitHub Profile
View shadowsocks
case "$1" in
/usr/bin/ulimit -n 51200
/usr/sbin/ndd -set /dev/tcp tcp_conn_req_max_q 4096
/usr/sbin/ndd -set /dev/tcp tcp_conn_req_max_q0 8192
/opt/local/bin/ss-server -c /root/config.json -f /root/
/opt/local/bin/kill `cat /root/`
View mrtg.cfg
# Created by
# /opt/local/bin/cfgmaker --global "WorkDir: /opt/local/www/munin" --output /opt/local/etc/mrtg.cfg --ifref=name --ifref=descr public@localhost
### Global Config Options
### Global Defaults
LoadMIBs: /etc/sma/snmp/mibs/IF-MIB.txt
EnableIPv6: no
View nicstat.c
* nicstat - print network traffic, Kb/s read and written. Solaris 8+.
* "netstat -i" only gives a packet count, this program gives Kbytes.
* 25-Jul-2006, ver 0.92 (check for new versions,
* cc -lgen -lkstat -lrt -o nicstat nicstat.c
* USAGE: nicstat [-hsz] [-i int[,int...]] | [interval [count]]
View gist:5107642


Twitter for iPhone

Consumer key: IQKbtAYlXLripLGPWd0HUA
Consumer secret: GgDYlkSvaPxGxC4X8liwpUoqKwwr3lCADbz8A7ADU

Twitter for Android

Consumer key: 3nVuSoBZnx6U4vzUxf5w
Consumer secret: Bcs59EFbbsdF6Sl9Ng71smgStWEGwXXKSjYvPVt7qys

Twitter for iPad

Consumer key: CjulERsDeqhhjSme66ECg

View gist:4491444
22213: shadowsocks-server
08048000 1708K r-x-- /usr/local/go/bin/shadowsocks-server
081f3000 68K rw--- /usr/local/go/bin/shadowsocks-server
08204000 4164K rw--- [ anon ]
08700000 261888K ----- [ anon ]
186c0000 2304K rwx-- [ anon ]
18900000 522240K ----- [ anon ]
b4ad5000 4K ----- [ anon ]
b4ad6000 8188K rw--- [ anon ]
b52d5000 256K rwx-- [ anon ]
madeye /
Created Dec 21, 2012
Set Wifi Proxy for Android
package me.madeye;
import android.content.Context;
import android.os.Handler;
import android.util.Log;
import java.util.List;
madeye /
Created Apr 4, 2012
Set proxy for Android Webview
package me.madeye;
import java.lang.reflect.Constructor;
import java.lang.reflect.Field;
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import org.apache.http.HttpHost;
import android.content.Context;
madeye / loop
Created Nov 14, 2011
parallel loop
View loop
#include <omp.h>
int main(int args, char **argv) {
int procs = omp_get_num_procs();
#pragma omp parallel
while (1);
return 0;