Skip to content

Instantly share code, notes, and snippets.

View tribela's full-sized avatar

Jeong Arm tribela

View GitHub Profile
tribela / vimrc
Created October 22, 2013 20:07
vimrc config
"color desert
colo slate
se nu
se ru
se sw=4
se sts=4
se ts=4
se ai
se cin
set smartindent
tribela / .pentadactylrc
Last active December 26, 2015 19:19
pentadactyl configure file
loadplugins '\.(js|penta)$'
group user
highlight Hint font: bold 20px "Source Code Pro", monospace !important; margin: -.2ex; padding: 0 0 0 1px; outline: 1px solid rgba(0, 0, 0, .5); background: rgba(255, 248, 231, .8) !important; color: black !important;
map -count -modes=n j -builtin <count><C-d>
map -count -modes=n k -builtin <count><C-u>
"set autocomplete=
set guioptions=brs
set hintkeys=asdfg;lkjhweio
tribela / prompt.rb
Created February 20, 2014 02:48
ruby readline while printing
# encoding: UTF-8
require "EventMachine"
require "readline"
prompt = '⚡ '
def mutex
@mutex ||
require 'net/http'
require 'uri'
Earthquake.init do
output_filter do |item|
next unless item['text']
text = item["text"]
text.scan( /http:\/\/t\.co\/[a-zA-Z0-9\-]+/ ).each do |url|
uri = URI.parse url
Net::HTTP::start( , uri.port ) do |connection|
connection.request_get uri.path do |response|
// ==UserScript==
// @name Facebook autopoke
// @namespace Kjwon15
// @description Facebook auto revenge poke
// @include http://**
// @include https://**
// ==/UserScript==
if (document.location.pathname.startsWith('/pokes') === false) {
# coding:utf-8
from contextlib import closing
from six.moves import urllib
from lxml import html
indexes = [
u'ㄱ', u'ㄴ', u'ㄷ', u'ㄹ', u'ㅁ', u'ㅂ', u'ㅅ', u'ㅇ', u'ㅈ', u'ㅊ', u'ㅋ',
u'ㅌ', u'ㅍ', u'ㅎ',
u'A', u'B', u'C', u'D', u'E', u'F', u'G', u'H', u'I', u'J', u'K', u'L',
tribela / gist:6a044c733e43ffb629b6
Created July 27, 2014 14:15
Proxy is poisoned
import os
import sys
from PIL import Image
def dhash(image, hash_size=8):
image = image.convert('L').resize(
(hash_size + 1, hash_size),
diff = []
tribela /
Last active August 29, 2015 14:13
Mininet custom topologies
from mininet.topo import Topo
class RingTopo(Topo):
def __init__(self, switch_count=4, host_count=1):
switches = [self.addSwitch('s{0}'.format(i+1))
for i in range(switch_count)]
tribela /
Last active November 7, 2015 07:59
bandcamp album downloader
import Queue
import json
import os
import re
import sys
import threading
import urllib2
from contextlib import closing
URL_FORMAT = 'http://{0}{1}/{2}'