This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-----BEGIN CERTIFICATE----- | |
[...] | |
-----END CERTIFICATE----- | |
-----BEGIN RSA PRIVATE KEY----- | |
[...] | |
-----END RSA PRIVATE KEY----- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var harp = require("harp") | |
harp.compile("source", "www", function(errors, output){ | |
console.log(output) | |
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var m = React.createElement | |
var Header = React.createClass({ | |
role: 'Header', | |
render: function(){ | |
return m("header", { role:"banner" }, | |
m("div", { id: "cd-logo" }, | |
m("a", {}, | |
m("img", { src: "img/cd-logo.svg", alt: "Logo" }) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class String | |
def title_case! | |
self.split.map{ |w| w.capitalize }.join(' ') | |
end | |
end | |
class Hash | |
def title_case_keys! | |
self.each_pair do |k,v| |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module StateMachine | |
def self.included(klass) | |
klass.extend ClassMethods | |
end | |
def self.wrap_method(klass, name) | |
original_method = "original_#{name}" | |
before_method = "before_#{name}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set :application, "phonegap" | |
set :deploy_to, "/var/www/phonegap.com" | |
set :tmp, "#{application}_update" | |
set :app_root, "/" | |
set :user, "root" | |
set :use_sudo, true | |
role :web, "phonegap.com" | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'rubygems' | |
require "hpricot" | |
PHONEGAP_WEB_PATH = "iphone/www" | |
namespace :iphone do | |
task :default => [:import] do | |
end | |
desc 'reverts file back to original form' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
####################### | |
# Merb.run_later issues | |
####################### | |
Here is what I am running. | |
- Slicehost account | |
- Ubuntu 8.04 | |
- jruby 1.1.5 (ruby 1.8.6 patchlevel 114) (2008-11-03 rev 7996) [amd64-java] | |
- glassfish V3 (0.9.1) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<meta http-equiv="Content-type" content="text/html; charset=utf-8"> | |
<title>Page Title</title> | |
<script type="text/javascript" charset="utf-8"> | |
//paste XUI here | |
getImage = function(){ | |
x$("#imagebox").xhr("http://api.flickr.com/services/feeds/photos_public.gne?tags=cat&tagmode=any&format=json&jsoncallback=?", | |
{callback:function(){ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# ##################################### | |
# Who is the killer? | |
# ##################################### | |
# | |
# Handel has been killed and Beethoven is on the case. He has | |
# interviewed the four suspects and their statements are shown below. | |
# Each suspect has said two sentences. One sentence of each suspect is a | |
# lie and one sentence is the truth. Help Beethoven figure out who the | |
# killer is. |