Skip to content

Instantly share code, notes, and snippets.

View kaiuhl's full-sized avatar
💭
Hi I'm alive

Kyle Meyer kaiuhl

💭
Hi I'm alive
View GitHub Profile
### Keybase proof
I hereby claim:
* I am kaiuhl on github.
* I am kaiuhl (https://keybase.io/kaiuhl) on keybase.
* I have a public key ASA5W2dGRmUaOFLxADZTs468dOycv8B88jPv_b9l31ogJAo
To claim this, I am signing this object:
<!DOCTYPE html>
<html>
<head>
<title>Treehouse is down for maintenance!</title>
<style>
body {
background: #384047;
text-align: center;
font-family: helvetica, arial, sans-serif;
color: #fff;
@kaiuhl
kaiuhl / gist:5366445
Created April 11, 2013 19:26
Fixing OpenSSL with RVM on Mac OS
Faraday::Error::ConnectionFailed SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed

This happens when RVM's new dependency handling (autolibs) installs OpenSSL and links it to Ruby, but OpenSSL doesn't has access to the SSL certificates already installed on the system.

To fix this

  1. Download a certificate pem file. curl.haxx.se provides automated conversions from Mozilla here. I saved it to ~/.ssh/.

  2. Add export SSL_CERT_FILE=$HOME/.ssh/cacert.pem to your .bash_profile

var Konami=function(){var a={addEvent:function(b,c,d,e){if(b.addEventListener)b.addEventListener(c,d,false);else if(b.attachEvent){b["e"+c+d]=d;b[c+d]=function(){b["e"+c+d](window.event,e)};b.attachEvent("on"+c,b[c+d])}},input:"",pattern:"3838404037393739666513",load:function(b){this.addEvent(document,"keydown",function(c,d){if(d)a=d;a.input+=c?c.keyCode:event.keyCode;if(a.input.length>a.pattern.length)a.input=a.input.substr(a.input.length-a.pattern.length);if(a.input==a.pattern){a.code(b);a.input=
""}},this);this.iphone.load(b)},code:function(b){window.location=b},iphone:{start_x:0,start_y:0,stop_x:0,stop_y:0,tap:false,capture:false,orig_keys:"",keys:["UP","UP","DOWN","DOWN","LEFT","RIGHT","LEFT","RIGHT","TAP","TAP","TAP"],code:function(b){a.code(b)},load:function(b){this.orig_keys=this.keys;a.addEvent(document,"touchmove",function(c){if(c.touches.length==1&&a.iphone.capture==true){c=c.touches[0];a.iphone.stop_x=c.pageX;a.iphone.stop_y=c.pageY;a.iphone.tap=false;a.iphone.capture=false;a.iphone.check_directio
@kaiuhl
kaiuhl / Potential View
Created December 22, 2010 20:49
Simple metaprogramming table for displaying simple administrative interfaces in Rails
<% title "Administrative Console" %>
<h1>Administrative Console</h1>
<h2>Latest News</h2>
<%= render(:partial => "tablify", :locals => { :array => @posts, :title => "title" }) %>
<h2>Meetings</h2>
<%= render(:partial => "tablify", :locals => { :array => @meetings, :title => "title" }) %>
<h2>Pages</h2>
<%= render(:partial => "tablify", :locals => { :array => @statics, :title => "title" }) %>
/******************************************
Flickr Javascript Library, alpha 1
Copyright (c) 2008 Kyle Meyer (kylemeyer.com)
Dual licensed under the MIT (MIT-LICENSE.txt)
and GPL (GPL-LICENSE.txt) licenses.
Last updated November, 2008
******************************************/
/******************************************
Flickr Javascript Library, alpha 1
Copyright (c) 2008 Kyle Meyer (kylemeyer.com)
Licensed under the MIT (MIT-LICENSE.txt)
Last updated November, 2008
******************************************/
@kaiuhl
kaiuhl / gentile-notices.js
Created May 15, 2009 22:12
A simple javascript to delicately remove notices from rails pages. Requires jQuery.
setTimeout(function(){
$("#flash_notice").add("#flash_error").fadeTo(2000, 0).animate({ height: "0px" }, 500)
},4000);