This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- encoding: utf-8 -*- | |
from __future__ import unicode_literals | |
import requests | |
from requests_oauthlib import OAuth1 | |
from urlparse import parse_qs | |
REQUEST_TOKEN_URL = "https://api.twitter.com/oauth/request_token" | |
AUTHORIZE_URL = "https://api.twitter.com/oauth/authorize?oauth_token=" | |
ACCESS_TOKEN_URL = "https://api.twitter.com/oauth/access_token" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# more usable | |
./generate.sh ./chn.txt \ | |
--net=CN \ | |
--vpn=US,HK,TW,AU,NZ \ | |
--nodefaultgw=1 \ | |
--profile=custom \ | |
--groupgw=1 \ | |
--netgw=wan \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# copied from: http://code.google.com/p/chnroutes/source/browse/trunk/chnroutes.py | |
import re | |
import urllib2 | |
import sys | |
import argparse | |
import math | |
import json | |
def fetch_ip_data(): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env node | |
'use strict'; | |
var fs = require('fs'); | |
var http = require('http'); | |
var https = require('https'); | |
var net = require('net'); | |
var url = require('url'); | |
var util = require('util'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Copyright: Benjamin Weiss (keyboardsurfer) https://github.com/keyboardsurfer | |
# Under CC-BY-SA V3.0 (https://creativecommons.org/licenses/by-sa/3.0/legalcode) | |
# built application files | |
*.apk | |
*.ap_ | |
*.jar | |
!gradle/wrapper/gradle-wrapper.jar | |
# lint folder |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Build "file" binary and "libmagic" library for use in Travis CI. | |
# Note: All relevant environment variables are set during the Travis CI run, | |
# see the following for details: https://github.com/kwilczynski/ruby-magic | |
set -e | |
set -o pipefail |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
0.0.0.0 | |
1.1.80.147 | |
1.1.127.45 | |
1.33.190.70 | |
1.33.191.58 | |
1.209.208.200 | |
1.234.1.235 | |
1.234.2.155 | |
1.234.4.97 | |
1.234.17.34 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
http://d.stavrovski.net/blog/post/how-to-install-and-setup-oracle-java-jdk-in-centos-6 | |
# rpm | |
wget --no-cookies \ | |
--no-check-certificate \ | |
--header "Cookie: oraclelicense=accept-securebackup-cookie" \ | |
"http://download.oracle.com/otn-pub/java/jdk/7u55-b13/jdk-7u55-linux-x64.rpm" \ | |
-O jdk-7-linux-x64.rpm | |
# ubuntu |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash -x | |
## original author: Oliver Nassar <onassar@gmail.com> | |
## credit: harmy <hack4cn@gmail.com> | |
## Ubuntu VPN for poor Chinese (you know de) | |
## Sample Usage: | |
## | |
## wget https://gist.github.com/raw/3891178/ff1702fac175eb21c513b93f51f39948be693aba/vpn-setup.sh | |
## chmod +x vpn-setup.sh | |
## sudo ./vpn-setup.sh <username> <password> |
OlderNewer