Skip to content

Instantly share code, notes, and snippets.

View tiff's full-sized avatar

Christopher Blum tiff

View GitHub Profile
@maettig
maettig / LICENSE.txt
Created November 21, 2011 16:13 — forked from 140bytes/LICENSE.txt
getElementsByClassName in 140byt.es
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 Thiemo Mättig <http://maettig.com/>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@jed
jed / LICENSE.txt
Created August 30, 2011 23:01 — forked from 140bytes/LICENSE.txt
isSameOrigin
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 YOUR_NAME_HERE <YOUR_URL_HERE>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@aemkei
aemkei / LICENSE.txt
Created May 24, 2011 08:34 — forked from 140bytes/LICENSE.txt
140byt.es - Base64 Encoder / Decoder
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 YOUR_NAME_HERE <YOUR_URL_HERE>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@phillipoertel
phillipoertel / parse_css_colors.rb
Created March 6, 2011 19:06
Get the colors from a CSS file, sorted by how often they occurr.
require 'open-uri'
#uri = "http://www.zeldman.com/wp-content/themes/zeldman-v2/style.css?0111110710"
#uri = "http://asset2.betterplace.org/stylesheets/screen.css?1299172234"
uri = 'http://www.xing.com/css/v/144/general.min.css'
def parse_css_colors(uri)
file = open(uri).read
hex_colors = file.scan(/#[a-f0-9]{3,6}/i)