Skip to content

Instantly share code, notes, and snippets.

View fengluo's full-sized avatar
:octocat:
Working

Shawn Xie fengluo

:octocat:
Working
View GitHub Profile
server {
root /wordpress_path;
index index.html index.htm index.php;
# Make site accessible from http://localhost/
server_name server_names;
client_max_body_size 10m;
# enforce www (exclude certain subdomains)

#The Great Firewall (GFW) Contributors List

注:数据来源为 dblp 和 cndblp, 下面括号中的数字表示 dblp 中显示的跟方滨兴合作论文的数量

###Binxing Fang (方滨兴)

中国工程院院士,北京邮电大学教授,中国科学院计算技术研究所网络方向首席科学家
http://en.wikipedia.org/wiki/Fang_Binxing

@fengluo
fengluo / post-update
Created August 21, 2014 03:05
Git deploy hooks
#!/bin/sh
#
# This hook does two things:
#
# 1. update the "info" files that allow the list of references to be
# queries over dumb transports such as http
#
# 2. if this repository looks like it is a non-bare repository, and
# the checked-out branch is pushed to, then update the working copy.
# This makes "push" function somewhat similarly to darcs and bzr.
echo "backup sources.list..."
sudo cp /etc/apt/sources.list /etc/apt/sources.list.bk
echo "wget new sources and write into sources.list"
sudo wget -c https://gist.github.com/fengluo/4754497/raw/ff5e00b83c9f785f1d75e0f98ff822c7ccd50e61/ubuntu-source-12.04 -O /etc/apt/sources.list
echo "update sources"
sudo apt-get update
sudo apt-get upgrade
echo "install packages..."
sudo apt-get install openssh-server curl
deb http://mirrors.163.com/ubuntu/ precise main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ precise-security main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ precise-updates main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ precise-proposed main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ precise-backports main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ precise main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ precise-security main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ precise-updates main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ precise-proposed main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ precise-backports main restricted universe multiverse
@fengluo
fengluo / browser-text-editor-for-python
Created January 31, 2013 02:55
This is a online text editor for python based on browser. It can be stored by pressing ctrl-s.
data:text/html,
<style type="text/css">
#e {
position:absolute;
top:0;
right:0;
bottom:0;
left:0;
font-size:14px;
}
@fengluo
fengluo / vimrc
Last active October 10, 2015 20:58
vimrc
" System
set nocompatible
filetype off
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
Bundle 'gmarik/Vundle.vim'
"Github bundles
Bundle "tpope/vim-fugitive"
Bundle "tpope/vim-markdown"
@fengluo
fengluo / gist:3305826
Created August 9, 2012 16:50 — forked from saetia/gist:1623487
Clean Install – Mountain Lion OS X 10.8 DP3 Update 4
@fengluo
fengluo / gist:3305821
Created August 9, 2012 16:50 — forked from saetia/gist:1623487
Clean Install – Mountain Lion OS X 10.8 DP3 Update 4