Skip to content

Instantly share code, notes, and snippets.

@flyingoctopus
flyingoctopus / setup.md
Last active August 15, 2018 09:10
Set up Textmate for Rails usage

##Setup Textmate for Rails Dev on OS X

##File/Folder Patterns

Wouldn't it be nice to be able to see hidden files and folders when working on a project in Textmate? As it turns out, it's built right in! Modify a few regex details with the tips below.

@flyingoctopus
flyingoctopus / gist:5760128
Created June 11, 2013 20:03
macbook-like breathing algo.
#include <math.h>
void setup()
{
pinMode(11, OUTPUT);
}
void loop()
{
float val = (exp(sin(millis()/2000.0*PI)) - 0.36787944)*108.0;
class Foo
include Mongoid::Document
field :bar
end
foo = Foo.new(:bar => "baz")
foo.to_json # => { _id: "(some uuid)", bar: "baz" }
@flyingoctopus
flyingoctopus / wavelength.md
Created January 25, 2013 00:23
for those that dont like the fb walled garden

Saturday 9:00pm until 4:00am

577 Great Northern Way, Vancouver, BC

There are several ways to get tickets!

Online at: http://northerntickets.com/events.php?s=wavelength Paper tickets available at High Life on Commercial Drive and Red Cat on Main Street Or, you can contact Chelsea or Ben who also have paper tickets available!

<div id="container">
<ul>
<li data-row="1" data-col="1" data-sizex="1" data-sizey="1"></li>
<li data-row="1" data-col="2" data-sizex="1" data-sizey="1"></li>
<li data-row="1" data-col="3" data-sizex="1" data-sizey="1"></li>
<li data-row="1" data-col="4" data-sizex="1" data-sizey="1"></li>
<li data-row="1" data-col="5" data-sizex="1" data-sizey="1"></li>
</ul>
</div>
@flyingoctopus
flyingoctopus / view.js.coffee
Created December 13, 2012 10:58
gridster + coffeescript + backbone data binding issue
class Namespace.Views.View extends Backbone.View
gridster: null
initialize: ->
@render()
render: =>
$(@el).html JST['templates/page'](key: 'value')
@loadGridster()
@flyingoctopus
flyingoctopus / .gitignore
Created November 8, 2012 06:50
openFrameworks/Apps level .gitignore
# flyingoctoApps is the only official directory
!flyingoctoApps/
# ignore bin folders' contents, except data folder therein
/flyingoctoApps/*/bin/*
!/flyingoctoApps/*/bin/data/
/flyingoctoApps/*/.cproject
/flyingoctoApps/*/.project
/flyingoctoApps/*/.settings/
@flyingoctopus
flyingoctopus / .gitignore
Created November 8, 2012 06:46
xcode project level gitignore
#########################
# .gitignore file for Xcode4 / OS X Source projects
#
# NB: if you are storing "built" products, this WILL NOT WORK,
# and you should use a different .gitignore (or none at all)
# This file is for SOURCE projects, where there are many extra
# files that we want to exclude
#
# For updates, see: http://stackoverflow.com/questions/49478/git-ignore-file-for-xcode-projects
#########################
We couldn’t find that file to show.
@flyingoctopus
flyingoctopus / _form.html.haml
Created July 19, 2012 19:02
event time fuckaduck
#event
= error_messages_for @event
.row
= form_for @event, :class => 'form-vertical' do |form|
.span8
.row
.span4
= form.label 'Date'
= form.date_select :start_date, {}, :class=>"span1"
.span4