Skip to content

Instantly share code, notes, and snippets.

<?xml version="1.0" encoding="UTF-8"?>
<Response>
<Dial timeout="10">706-325-2079</Dial>
<Dial timeout="15">404-451-0516</Dial>
<Say>Hello, you have reached Tourbuzz. Please leave us a message and we will get back to you as soon as possible.</Say>
<Record transcribe="true" transcribeCallback="http://twimlets.com/voicemail?Email=support@tourbuzz.net"/>
</Response>
@lorennorman
lorennorman / hello.cljs
Created January 5, 2015 22:00
dirty dirty maze generator to learn clojure(script)
(ns cljsgame.hello)
(enable-console-print!)
(defn create []
(cljsgame.maze-builder.add-chrome cljsgame.hello.game))
(defn update []
(cljsgame.maze-builder.step))
/* mobile first */
.bathroom.label-icon {
@include tb-icon('bathroom', ms(3)); // Font size in tb-icon call required
}
.bedroom.label-icon {
@include tb-icon('bedroom', ms(3)); // Font size in tb-icon call required, ugly repetition
}
@lorennorman
lorennorman / gist:91403
Created April 7, 2009 19:02
My favorite Rails setup.
# My Rails 2.3 Template
# You can use it like this:
# rails your_app_name -m http://gist.github.com/91403.txt
# Plugins
plugin 'rspec', :git => 'git://github.com/dchelimsky/rspec.git'
plugin 'rspec-rails', :git => 'git://github.com/dchelimsky/rspec-rails.git'
plugin 'role_requirement', :git => 'git://github.com/lorennorman/role_requirement.git'
plugin 'restful-authentication', :git => 'git://github.com/technoweenie/restful-authentication.git'
plugin 'aasm', :git => 'git://github.com/rubyist/aasm.git'
@lorennorman
lorennorman / Basic Git
Created September 26, 2009 20:03
A Rails template for a bare bones, but checked in, install. Used this as a starting point and add your favorite gems, scripts, and libraries.
# Basic Rails project, default files cleaned up and checked into Git
# Partly taken from: http://github.com/jeremymcanally/rails-templates/blob/master/newgit.rb
# Use it like this:
# rails your_app_name -m http://gist.github.com/194395.txt
# rails:rm_tmp_dirs
["./tmp/pids", "./tmp/sessions", "./tmp/sockets", "./tmp/cache"].each do |f|
run("rmdir ./#{f}")
end
# STI Models
class Question < AR::Base; end # should never be instantiated
class YesNoQuestion < Question; end # should
class TextQuestion < Question; end # should
# etc...
# Form.rb (model)
accepts_nested_attributes_for :questions # except I don't want to instantiate Question!
# forms/edit.html.erb (view)
# Stolen from: http://railstips.org/blog/archives/2009/10/09/more-mongomapper-awesomeness/
class User
include MongoMapper::Document
many :posts
end
class Post
include MongoMapper::Document
<% semantic_form_for @model_name do |form| %>
<%= form.inputs %>
<%= form.buttons %>
<% end %>
// Watches the spec files for changes and reloads the Jasmine test runner
// Watches the source files for changes and auto-builds with Sprockets
// Rebuilds also trigger the tests
var SOURCE_DIR = "src";
var SOURCE_MAIN = SOURCE_DIR+'/application.js';
var BUILD_DIR = 'build';
var BUILD_MAIN = BUILD_DIR+'/application.js';
var SPEC_DIR = 'spec';
var WATCH_INTERVAL = 5000;
// Let's specify some Behaviors, first
// Gotta have x,y coords!
var Positionable =
{ x: 0
, y: 0 // phear my inverted c0mmaZ!
};
// Mmmm, delicious physics
var Physical =