Skip to content

Instantly share code, notes, and snippets.

View YieldNull's full-sized avatar
😃

YieldNull

😃
View GitHub Profile
@YieldNull
YieldNull / goslate.py
Created November 17, 2015 13:47
Translate English and Chinese mutually using https://translate.google.com.hk
#!/usr/bin/env python
# coding:utf-8
"""
Translate English and Chinese mutually using https://translate.google.com.hk
create on '11/5/15 5:07 PM'
"""
import gzip
import httplib
#!/usr/bin/env python
# coding:utf-8
"""
A 'Crawler' for http://msdn.itellyou.cn/
"""
import re
import urllib
import urllib2
@YieldNull
YieldNull / R2LParser.c
Created November 1, 2015 12:44
Recognize C Pointer Declaration(识别C语言指针表达式)
/*
* R2LParser.c
*
* Recognize C declaration use Right-Left Method(from http://ieng9.ucsd.edu/~cs30x/rt_lt.rule.html)
*
* The "right-left" rule is a completely regular rule for deciphering C
* declarations. It can also be useful in creating them.
*
* First, symbols. Read
* * as "pointer to" - always on the left side
@YieldNull
YieldNull / CParser.jj
Created October 27, 2015 07:28
C grammar defintion for use with JavaCC.(Copied from https://java.net/downloads/javacc/contrib/grammars/C.jj)
/*
C grammar defintion for use with JavaCC
Contributed by Doug South (dsouth@squirrel.com.au) 21/3/97
This parser assumes that the C source file has been preprocessed : all
#includes have been included and all macros have been expanded. I accomplish
this with "gcc -P -E <source file> > <output file>".
There is a problem with compiler specific types, such as __signed, __const,
@YieldNull
YieldNull / neteasy.py
Last active October 26, 2015 12:26
Backup your neteasy blog entries to a sqlite3 database (备份网易博客)
#!/usr/bin/env python
# coding:utf-8
"""
Backup your neteasy blog entries to a sqlite3 database
Usage neteasy.py <username>
The username is your blog name which appears in your blog domain.
Just like "junjie.blog.163.com", in which "junjie" is the <username>
@YieldNull
YieldNull / ruijie.py
Last active November 17, 2015 15:43
Login in WHU Dormitory Network(登陆武汉大学宿舍校园网)网页认证
#!/usr/bin/env python
# coding:utf-8
"""
Login in WHU Dormitory Network
Usage:
Usage: ruijie.py [-l]
-l to logout
@YieldNull
YieldNull / readme.md
Last active July 14, 2021 04:31
爬取新浪微博中指定用户所有相册图片,并保存到本地

功能

给定用户的ID(微相册的数字ID,非昵称),下载用户相册中所有图片到本地

所需模块

rsa,threadpool

登陆

请先更改login_weibo中的用户名及密码

用法