Skip to content

Instantly share code, notes, and snippets.

View ZhangYiJiang's full-sized avatar
🎼
Practising his hemidemisemiquaver

Zhang Yi Jiang ZhangYiJiang

🎼
Practising his hemidemisemiquaver
View GitHub Profile
@ZhangYiJiang
ZhangYiJiang / voting-ponies.user.js
Last active December 15, 2015 05:38
Watch Karma and Descentia vote for you as you click on the up and downvote button on r/mylittlepony
// ==UserScript==
// @name Voting Ponies
// @namespace yijiang
// @include http://www.reddit.com/r/mylittlepony*
// @version 1.1
// ==/UserScript==
function inject () {
var images = ['http://i.imgur.com/nXc1LOz.gif', 'http://i.imgur.com/jQ70FcY.gif',
'http://i.imgur.com/YIJWhes.gif', 'http://i.imgur.com/45wWH0C.gif'];
with open('1.in') as f:
data = f.read()
print('First half')
print(data.count('(') - data.count(')'))
i = 0
floor = 0
while floor >= 0:
@ZhangYiJiang
ZhangYiJiang / tag_remover.user.js
Last active November 1, 2015 07:57
Stack Exchange Title Tag Remover
// ==UserScript==
// @name Stack Exchange Title Tag Remover
// @namespace yijiang
// @include http://stackoverflow.com/questions/*
// @include http://superuser.com/questions/*
// @include http://serverfault.com/questions/*
// @include http://askubuntu.com/questions/*
// @include http://answers.onstartups.com/questions/*
// @include http://nothingtoinstall.com/questions/*
// @include http://seasonedadvice.com/questions/*
// ==UserScript==
// @name Asslandia
// @namespace yijiang
// @include http://www.glitch.com/*
// @version 1.01
// ==/UserScript==
// NEVER FORGET LNVG40H1DOD392I :(
var assLinks = document.querySelectorAll('a[href*="LA9BT2I0ILD340S"]');
@ZhangYiJiang
ZhangYiJiang / README.md
Created August 28, 2012 03:59
Glitch Forum Remix

To configure this script, open your browser's console (F12) and copy this in

localStorage.remixSetting = JSON.stringify({
	// Add or remove forums to load by editing these. 
	enabledForum: ['announcements', 'bugs', 'ideas', 'marketplace'], 
	otherForumCount: 6, // Number of posts to show from the other forum
	generalForumCount: 10, // Number of posts to show from General 
	cacheTime: 10 // Amount of time to cache the results from other forums in minutes
});
@ZhangYiJiang
ZhangYiJiang / mass_glitch_mail.user.js
Created August 20, 2012 07:24
Glitch mass mail delete userscript
// ==UserScript==
// @name Mass delete Glitch mail messages
// @namespace yijiang
// @include http://www.glitch.com/mail/
// @include http://www.glitch.com/mail/all/
// @version 1.04
// ==/UserScript==
function init() {
function deleteMessage (message) {
@ZhangYiJiang
ZhangYiJiang / api_wrapper.js
Created January 25, 2011 07:06
Lightweight SE API Wrapper
var apikey = 'xxxxxxxxxxxxxxxx',
apiPrefix = 'http://api.stackoverflow.com/1.0/';
if(!Date.now) {
Date.now = function () {
return +new Date();
};
}
var api = {