This file contains hidden or 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
| install PostgreSQL 9 in Mac OSX via Homebrew | |
| Mac OS X Snow Leopard | |
| System Version: Mac OS X 10.6.5 | |
| Kernel Version: Darwin 10.5.0 | |
| Install notes for PostgreSQL 9.0.1 install using Homebrew: | |
| sh-3.2# brew install postgresql |
This file contains hidden or 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
| Function::property = (prop, desc) -> | |
| Object.defineProperty @prototype, prop, desc | |
| class Person | |
| constructor: (@firstName, @lastName) -> | |
| @property 'fullName', | |
| get: -> "#{@firstName} #{@lastName}" | |
| set: (name) -> [@firstName, @lastName] = name.split ' ' | |
| p = new Person 'Leroy', 'Jenkins' |
This file contains hidden or 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 'pathname' | |
| require 'rbconfig' | |
| require 'fileutils' | |
| module BasicMoai | |
| ROOT_FOLDER = File.expand_path(File.join(File.dirname(__FILE__), "..")) | |
| SRC_FOLDER = File.join(ROOT_FOLDER, "src") | |
| VENDOR_FOLDER = File.join(ROOT_FOLDER, "vendor") | |
| TMP_FOLDER = File.join(ROOT_FOLDER, "tmp") |
This file contains hidden or 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
| /** | |
| * Space invaders generator. Generates and draws invaders. Inspired | |
| * by invaders fractals: | |
| * http://www.levitated.net/daily/levInvaderFractal.html | |
| * | |
| * Mouse press will create new invaders and draw the new ones. | |
| */ | |
| /** Scaling factor */ | |
| float sc = 3f; |
This file contains hidden or 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
| def should_behave_like_resource(opts = {}) | |
| before :each do | |
| @opts = opts | |
| end | |
| def class_for(str) | |
| str.capitalize.constantize | |
| end | |
| def clazz |