https://github.com/harrah/xsbt/wiki/Getting-Started-Setup
https://github.com/n8han/conscript
https://github.com/n8han/giter8
# by ifconfig | |
ifconfig eth1:0 10.1.53.1 | |
ifconfig eth1:0 down | |
# by iproute2 | |
ip addr add 10.1.53.1 dev eth1 | |
ip addr show | |
ip addr del 10.1.53.1 dev eth1 |
#!/bin/sh | |
curl -sL 'https://github.com/downloads/libevent/libevent/libevent-2.0.20-stable.tar.gz' | tar zx | |
cd libevent-2.0.20-stable/ | |
./configure --prefix=/usr/local/libevent/2.0.20-stable | |
make | |
sudo make install | |
sudo alternatives --install /usr/local/lib64/libevent libevent /usr/local/libevent/2.0.20-stable/lib 20018 \ | |
--slave /usr/local/include/libevent libevent-include /usr/local/libevent/2.0.20-stable/include \ | |
--slave /usr/local/bin/event_rpcgen.py event_rpcgen /usr/local/libevent/2.0.20-stable/bin/event_rpcgen.py |
# install boost-1.49.0 | |
cd ~/src | |
curl -L "http://downloads.sourceforge.net/project/boost/boost/1.49.0/boost_1_49_0.tar.gz?r=http%3A%2F%2Fwww.boost.org%2Fusers%2Fhistory%2Fversion_1_49_0.html&ts=1331091084&use_mirror=jaist" | tar zxv | |
cd boost_1_49_0 | |
./bootstrap.sh | |
./b2 | |
sudo ./b2 --prefix=/usr/local/boost_1_49_0 install |
package org.sazabi.lib.preference; | |
import android.content.Context; | |
import android.content.res.TypedArray; | |
import android.graphics.drawable.Drawable; | |
import android.preference.Preference; |
SimpleDateFormat format = new SimpleDateFormat("E MMM d kk:mm:ss Z yyyy", Locale.US); | |
Date datetime = format.parse("Thu Jun 10 01:32:13 +0000 2010"); |
// grayscale color filter | |
float r = 0.298912F; | |
float g = 0.586611F; | |
float b = 0.114478F; | |
ColorMatrixFilter filter = new ColorMatrixFilter( | |
new ColorMatrix(new float[] { | |
r, g, b, 0, 0, | |
r, g, b, 0, 0, |