Skip to content

Instantly share code, notes, and snippets.

View tekkub's full-sized avatar

Tekkub tekkub

View GitHub Profile
@tekkub
tekkub / anti-expertsexchange.user.js
Created November 8, 2009 01:41
Google domain blacklist
// ==UserScript==
// @name Google domain blacklist
// @namespace http://www.google.com
// @description Removes results for specific domains from google.
// @include http://www.google.com/search*
// @include http://www.google.co.uk/search*
// ==/UserScript==
var blacklist = new Array("experts-exchange.com", "torrentreactor.to");
for (domain in blacklist) {
@tekkub
tekkub / gist:227475
Created November 5, 2009 22:45
What is the point of --verbose?
[tekkub@tekBook: ~ master*] $ git push origin master
Counting objects: 15, done.
Delta compression using 2 threads.
Compressing objects: 100% (6/6), done.
Writing objects: 100% (8/8), 588 bytes, done.
Total 8 (delta 4), reused 0 (delta 0)
To [email protected]:tekkub/backup-mini.git
504cae5..949dbed master -> master
[tekkub@tekBook: ~ master*] $ git push origin master --verbose
@tekkub
tekkub / github_dashboard_twitter.user.js
Created November 3, 2009 22:29
Add @github's tweets to your dashboard
// ==UserScript==
// @name GitHub Dashboard Twitter
// @namespace http://tekkub.net/
// @include https://github.com/
// ==/UserScript==
$("div.news h1").before(
$("<div>").attr("id", "twitter_div2").append(
$("<h1>").text("GitHub status ").css({
AzDKPForm:SetScript("OnEvent", function(self)
if GetNumRaidMembers() > 0 then self:Show()
else self:Hide() end
end)
AzDKPForm:RegisterEvent("RAID_ROSTER_UPDATE")
local function utf8sub(str, start, numChars)
local currentIndex = start
while numChars > 0 and currentIndex <= #str do
local char = string.byte(str, currentIndex)
if char >= 240 then currentIndex = currentIndex + 4
elseif char >= 225 then currentIndex = currentIndex + 3
elseif char >= 192 then currentIndex = currentIndex + 2
else currentIndex = currentIndex + 1 end
numChars = numChars - 1
end
local f = CreateFrame("frame")
f:SetScript("OnEvent", function(self, event, ...) if self[event] then return self[event](self, event, ...) end end)
f:RegisterEvent("PLAYER_LOGIN")
function f:PLAYER_LOGIN()
self:RegisterEvent("QUEST_QUERY_COMPLETE")
QueryQuestsCompleted()
@tekkub
tekkub / github_upload.rb
Created October 24, 2009 22:39
Command-line file uploader for GitHub
#!/usr/bin/env ruby
require "net/http"
require 'net/https'
require "rubygems"
require 'xmlsimple'
require 'mime/types'
module Net
<or>
<match path="project">thrae-wow</match>
<match path="project">dongle</match>
<match path="project">PerfectRaid</match>
<match path="project">LightHeaded</match>
<match path="project">PerfBlock</match>
<match path="project">legos-wow</match>
<match path="project">shadowed-wow</match>
<match path="project">guildbook-wow</match>
<match path="project">joshborke-wow</match>
Ace3
AddonLoader
BetterInbox
Butsu
ChatIcons
Clique
DropTheCheapestThing
EasySerum
InterfaceOptionsFrame_OpenToCategory_Fix
LightHeaded
{
:before => before,
:after => after,
:ref => ref,
:commits => [{
:id => commit.id,
:message => commit.message,
:timestamp => commit.committed_date.xmlschema,
:url => commit_url,
:added => array_of_added_paths,