Skip to content

Instantly share code, notes, and snippets.

View ahxxm's full-sized avatar
🚘
On The Road

ahxxm ahxxm

🚘
On The Road
View GitHub Profile
@ahxxm
ahxxm / ssxy.py
Created October 7, 2015 10:09
世说新语
# ssxy
import random
from twitter import *
from pymongo import MongoClient
client = MongoClient('localhost', 27017)
db = client.Shishuoxinyu
'''
k = oauth_dance('twitter_username',
@ahxxm
ahxxm / .gitmodule
Created September 26, 2015 14:13
gitmodule for dealM
[submodule "plugins/rainbow-mode"]
path = plugins/rainbow-mode
url = https://github.com/emacsmirror/rainbow-mode.git
[submodule "plugins/magit"]
path = plugins/magit
url = https://github.com/magit/magit.git
[submodule "plugins/yasnippet"]
path = plugins/yasnippet
url = https://github.com/chao787/yasnippet.git
[submodule "snippets"]
@ahxxm
ahxxm / google_drive_podcast_uploader.py
Created September 7, 2015 13:22
google_drive_podcast_uploader
import os
import trollius
from pydrive.auth import GoogleAuth
from pydrive.drive import GoogleDrive
# Auth Google Drive
gauth = GoogleAuth()
gauth.LoadCredentialsFile("creds.json")
@ahxxm
ahxxm / upyun_podcast_uploader.py
Last active September 7, 2015 13:29
upyun podcast uploader with filename-as-cache
import os
import upyun
from progressbar import *
# http://stackoverflow.com/questions/1192978/python-get-relative-path-of-all-files-and-subfolders-in-a-directory
myFolder = "/podcast/pod/podcasts/"
os.chdir(myFolder)
fileSet = set()
@ahxxm
ahxxm / QingCloud Debian7.5 One-Click PPT
Last active August 29, 2015 14:21
pptp for playing game
echo 'QingCloud Debian7.5 One-Click PPTP Server'
apt-get install pptpd
cat >> /etc/pptpd.conf<<-EOF
localip 10.0.0.1
remoteip 10.0.0.100-200
EOF
cat >>/etc/ppp/chap-secrets<<-EOF