code
stringlengths
1
1.73M
language
stringclasses
1 value
class Admin::MembersController < ApplicationController # GET /admin_members # GET /admin_members.xml def index @members = Member.paginate :page => params[:page], :per_page => 15, :joins => :person, :order => 'people.last_name, people.first_name' respond_to do |format| format.html # index.html.erb ...
Ruby
class Admin::PeopleLicensesController < ApplicationController before_filter :find_person def new @people_license = PeopleLicense.new end def edit @people_license = @person.people_licenses.find(params[:id]) end def create @people_license = PeopleLicense.new(params[:people_license]) if (@...
Ruby
class Admin::PeopleController < ApplicationController # GET /admin_people def index @people = Person.paginate :page => params[:page], :per_page => 15, :order => 'last_name, first_name', :conditions => 'deleted <> 1' respond_to do |format| format.html # index.html.erb format.xml { render :xml =...
Ruby
# Filters added to this controller apply to all controllers in the application. # Likewise, all the methods added will be available for all controllers. class ApplicationController < ActionController::Base helper :all # include all helpers, all the time # See ActionController::RequestForgeryProtection for details...
Ruby
# Be sure to restart your server when you modify this file. # Add new inflection rules using the following format # (all these examples are active by default): # ActiveSupport::Inflector.inflections do |inflect| # inflect.plural /^(ox)$/i, '\1en' # inflect.singular /^(ox)en/i, '\1' # inflect.irregular 'person',...
Ruby
# These settings change the behavior of Rails 2 apps and will be defaults # for Rails 3. You can remove this initializer when Rails 3 is released. if defined?(ActiveRecord) # Include Active Record class name as root for JSON serialized output. ActiveRecord::Base.include_root_in_json = true # Store the full clas...
Ruby
# Be sure to restart your server when you modify this file. # Add new mime types for use in respond_to blocks: # Mime::Type.register "text/richtext", :rtf # Mime::Type.register_alias "text/html", :iphone
Ruby
ActionController::Routing::Routes.draw do |map| #to trzeba zmienic na dobre, ale jeszcze nie wiem jak: map.connect 'admin/people/search', :controller => "admin::People", :action => "search" #licenses map.namespace :admin do |admin| admin.resources :licenses end map.resources :licenses #members ...
Ruby
# Don't change this file! # Configure your app in config/environment.rb and config/environments/*.rb RAILS_ROOT = "#{File.dirname(__FILE__)}/.." unless defined?(RAILS_ROOT) module Rails class << self def boot! unless booted? preinitialize pick_boot.run end end def booted? ...
Ruby
# Be sure to restart your server when you modify this file # Uncomment below to force Rails into production mode when # you don't control web/app server and can't set it the proper way # ENV['RAILS_ENV'] ||= 'production' # Specifies gem version of Rails to use when vendor/rails is not present RAILS_GEM_VERSION = '2.2...
Ruby
# Settings specified here will take precedence over those in config/environment.rb # The production environment is meant for finished, "live" apps. # Code is not reloaded between requests config.cache_classes = true # Enable threaded mode # config.threadsafe! # Use a different logger for distributed setups # config....
Ruby
# Settings specified here will take precedence over those in config/environment.rb # In the development environment your application's code is reloaded on # every request. This slows down response time but is perfect for development # since you don't have to restart the webserver when you make code changes. config.ca...
Ruby
# Settings specified here will take precedence over those in config/environment.rb # The test environment is used exclusively to run your application's # test suite. You never need to work with it otherwise. Remember that # your test database is "scratch space" for the test suite and is wiped # and recreated between...
Ruby
# Add your own tasks in files placed in lib/tasks ending in .rake, # for example lib/tasks/capistrano.rake, and they will automatically be available to Rake. require(File.join(File.dirname(__FILE__), 'config', 'boot')) require 'rake' require 'rake/testtask' require 'rake/rdoctask' require 'tasks/rails'
Ruby
$:.unshift File.join(File.dirname(__FILE__),'..','lib') $:.unshift File.join(File.dirname(__FILE__),'..','test') require 'helpers' require 'model' require 'bigdecimal' class CreateSampleTransactions def CreateSampleTransactions.execute m = Model.new(Dir.pwd) tx = [] tx << Helpers.transaction_simple...
Ruby
# # To change this template, choose Tools | Templates # and open the template in the editor. require 'rake' require 'rake/testtask' require 'rake/rdoctask'
Ruby
require 'pages/account_page' require 'pages/home_page' require 'pages/icons' require 'pages/ofx_page' require 'pages/report_page' require 'pages/util'
Ruby
require 'gtk2' require 'model' require 'pages' class BeanCounterUI def initialize(prefs) @prefs = prefs @model = Model.new(@prefs[:data_dir]) init_vars setup_application setup_tabs @app.show_all end def init_vars @tabs = [ ["Home", HomePage], ["Accounts", AccountPag...
Ruby
class Transaction attr_reader :total_debits, :total_credits, :entries, :date def initialize(date) @date = date @entries = [] @observers = [] @total_debits = 0 @total_credits = 0 end def add_credit(account, amount) @entries << { :tx_type => :credit, :account => account,...
Ruby
require 'bigdecimal' class Model attr_reader :accounts, :ofx def initialize(data_dir) @data_dir = data_dir @accounts = { "root" => Account.new("root", 0, nil)} @posted_tx = [] @max_tx_id = 0 @ofx = {} @max_ofx_id = 0 if(File.exists?(@data_dir)) load_data else create_da...
Ruby
# account knows about its name, its parent "account", how it should handle # debits and credits, and keeps track of its current balance. in pennies. class Account attr_reader :account_name, :parent_account, :increase_type attr_accessor :current_balance def initialize(account_name, increase_type, parent_account) ...
Ruby
require 'rexml/document' class OfxHeader attr_reader( :ofx_header, :data, :version, :security, :encoding, :charset, :compression, :old_file_uid, :new_file_uid ) def initialize(headers) headers.each do |h| key, value = h.split(":") case key.downcase wh...
Ruby
require 'model' class AccountTreeView < Gtk::VBox def initialize(model) super() @model = model @store = Gtk::TreeStore.new(String) setup_child_accounts(@model.root_account, nil) @view = Gtk::TreeView.new(@store) @view.append_column( Gtk::TreeViewColumn.new("Accounts", Gtk::CellRendererT...
Ruby
class CategorySummary < Gtk::VBox def initialize(account) super() self.pack_start(Gtk::Label.new(account.account_name)) self.pack_start(Gtk::Label.new(Util.to_usd(account.current_balance))) end end class HomePage < Gtk::VBox def initialize(model, prefs) super() @model = model @prefs = prefs ...
Ruby
class ReportPage < Gtk::VBox def initialize(model, prefs) super() @model = model @prefs = prefs end end
Ruby
class Icons @@src_dir = "pages/img" @@icons = { :open => "folder-open.png", :expand => "list-add.png" } def self.get_icon(name, size) return nil unless @@icons.has_key?(name) Gtk::Image.new(Gdk::Pixbuf.new("#{@@src_dir}/#{@@icons[name]}", size, size)) end end
Ruby
class Util def self.to_usd(cents) "$#{format("%.2f", cents)}".gsub(/(\d)(?=\d{3}+(\.\d*)?$)/, '\1,') end end
Ruby
class OfxListView < Gtk::VBox def initialize(model, prefs) super() @model = model @prefs = prefs @store = Gtk::ListStore.new(String) row = @store.insert(0) @model.ofx.each do |k,v| row[0] = k row = @store.insert_after(row) end #row[0] = "Import OFX File..." @v...
Ruby
require 'model/account' require 'model/model' require 'model/ofx' require 'model/transaction'
Ruby
class Helpers def Helpers.invalid_transaction tx = Transaction.new(Date.new(2008,7,16)) tx.add_debit(@account_checking, 6.67) return tx end def Helpers.transaction_simple(tx_date, acct_from, acct_to, amount) tx = Transaction.new(Date.parse(tx_date)) tx.add_credit(acct_from, amount) tx.add...
Ruby
require 'test/unit' require 'tc_account' require 'tc_transaction' require 'tc_model' require 'tc_ofx'
Ruby
$:.unshift File.join(File.dirname(__FILE__),'..','lib') require 'date' require 'fileutils' require 'pathname' require 'test/unit' require 'helpers' require 'model' class TcModel < Test::Unit::TestCase TEST_DIR = 'test_data' SAMPLE_DIR = 'sample_data' def setup FileUtils.rm_rf(TEST_DIR) @model = Mod...
Ruby
$:.unshift File.join(File.dirname(__FILE__),'..','lib') require 'test/unit' require 'model' class TcAccount < Test::Unit::TestCase def test_current_balance asset = Account.new("Test", :debit, nil) assert_equal(0.0, asset.current_balance) asset.journal(:debit, 123) assert_equal(123, asset.current_b...
Ruby
$:.unshift File.join(File.dirname(__FILE__),'..','lib') require 'test/unit' require 'helpers' require 'model' class TcTransaction < Test::Unit::TestCase def test_transaction_basic test_amt = BigDecimal.new("12.34") tx = Helpers.transaction_simple("2008-07-15", "Checking", "Expense", test_amt) assert...
Ruby
$:.unshift File.join(File.dirname(__FILE__),'..','lib') require 'test/unit' require 'model' class TcOfx < Test::Unit::TestCase TEST_DIR = 'test_data' SAMPLE_DIR = 'sample_data' def setup @ofx = Ofx.new("#{SAMPLE_DIR}/ofx_sample/checking.ofx") if @ofx.nil? end def test_ofx_header header = @o...
Ruby
class CreateUsers < ActiveRecord::Migration def up create_table :users do |t| t.string :profile_id t.string :email t.string :refresh_token end add_index :users, :profile_id end def down drop_table :users end end
Ruby
# Copyright (C) 2012 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writ...
Ruby
source :gemcutter gem 'sinatra', :require => 'sinatra/base' gem 'thin', '~> 1.3' gem 'pg' gem 'sinatra-activerecord' gem 'google-api-client', '>= 0.4.4', :require => 'google/api_client' group :development do gem 'rake' gem 'sqlite3-ruby' end
Ruby
require 'sinatra.rb' # Sinatra defines #set at the top level as a way to set application configuration set :run, false set :env, (ENV['RACK_ENV'] ? ENV['RACK_ENV'].to_sym : :development) require './main' run Sinatra::Application
Ruby
require 'sinatra/activerecord/rake' require './main'
Ruby
class AddHits < ActiveRecord::Migration def self.up add_column "posts", "hits", :integer, :default => 0 end def self.down remove_column "posts", "hits" end end
Ruby
class EmpowerSessions < ActiveRecord::Migration def self.up add_column "sessions", "user_id", :integer end def self.down remove_column "sessions", "user_id" end end
Ruby
class CreateForums < ActiveRecord::Migration def self.up create_table :forums do |t| t.column :name, :string end end def self.down drop_table :forums end end
Ruby
require 'digest/sha1' class AddPasswordHash < ActiveRecord::Migration class User < ActiveRecord::Base; end def self.up # you need to edit your environment.rb and pick a non-default password salt # before you continue raise "ChangePasswordHash" if PASSWORD_SALT == '48e45be7d489cbb0ab582d26e2168621' s...
Ruby
class CreateTopics < ActiveRecord::Migration class Post < ActiveRecord::Base; end class Topic < ActiveRecord::Base; end def self.up create_table :topics do |t| t.column "forum_id", :integer t.column "user_id", :integer t.column "title", :string t.column "created_at", :dat...
Ruby
class AddContactFields < ActiveRecord::Migration def self.up # to facilite better communication add_column "users", "aim", :string add_column "users", "yahoo", :string add_column "users", "google_talk", :string add_column "users", "msn", :string add_column "users", "website", :string end ...
Ruby
class NeededIndexes < ActiveRecord::Migration def self.up add_index :posts, :user_id add_index :posts, :topic_id add_index :topics, :forum_id end def self.down remove_index :posts, :user_id remove_index :posts, :topic_id remove_index :topics, :forum_id end end
Ruby
class AddPostsBodyHtml < ActiveRecord::Migration def self.up add_column "posts", "body_html", :text add_column "users", "bio_html", :text add_column "forums", "description_html", :text [Post, Forum, User].each do |klass| klass.transaction do klass.find(:all).each do |rec...
Ruby
class LastSeenAt < ActiveRecord::Migration def self.up add_column "users", "last_seen_at", :datetime end def self.down remove_column "users", "last_seen_at" end end
Ruby
class LogEveryoneOut < ActiveRecord::Migration def self.up Session.delete_all end def self.down raise IrreversibleMigration end end
Ruby
class SetStickyToZero < ActiveRecord::Migration class Topic < ActiveRecord::Base; end def self.up Topic.update_all ['sticky = 0'], ['sticky is null'] end def self.down end end
Ruby
class LoginByKeyFields < ActiveRecord::Migration def self.up add_column "users", "login_key", :string add_column "users", "login_key_expires_at", :datetime end def self.down remove_column "users", "login_key" remove_column "users", "login_key_expires_at" end end
Ruby
class FixForumPostsCount < ActiveRecord::Migration class Post < ActiveRecord::Base; end class Forum < ActiveRecord::Base; end def self.up Post.count(:all, :group => :forum_id).each do |forum_id, count| Forum.update_all ['posts_count = ?', count], ['id = ?', forum_id] end end def self.down en...
Ruby
class CleanUpPostsTable < ActiveRecord::Migration def self.up remove_column "posts", "title" remove_column "posts", "hits" remove_column "posts", "sticky" remove_column "posts", "posts_count" remove_column "posts", "replied_at" end def self.down end end
Ruby
class CreatePosts < ActiveRecord::Migration def self.up create_table :posts do |t| t.column :forum_id, :integer t.column :user_id, :integer t.column :post_id, :integer t.column :title, :string t.column :body, :text t.column :created_at, :datetime t.column :updated_at, :da...
Ruby
class CreateMonitorships < ActiveRecord::Migration def self.up create_table :monitorships do |t| t.column :topic_id, :integer t.column :user_id, :integer t.column :active, :boolean, :default => true end end def self.down drop_table :monitorships end end
Ruby
class ChangeStickyToInteger < ActiveRecord::Migration class Topic < ActiveRecord::Base; end def self.up sticky_topics = Topic.find_all_by_sticky(true).collect &:id change_column :topics, :sticky, :integer, :default => 0 Topic.update_all 'sticky=1', ['id in (?)', sticky_topics] end def self.down ...
Ruby
class TweakForumIndex < ActiveRecord::Migration def self.up remove_index :topics, :name => :index_topics_on_sticky_and_replied_at add_index :topics, [:forum_id, :sticky, :replied_at], :name => :index_topics_on_sticky_and_replied_at end def self.down remove_index :topics, :name => :index_topics_on_sti...
Ruby
class DisplayName < ActiveRecord::Migration def self.up add_column "users", "display_name", :string end def self.down remove_column "users", "display_name" end end
Ruby
class DeleteEmptyTopics < ActiveRecord::Migration class Post < ActiveRecord::Base; end class Topic < ActiveRecord::Base has_many :posts end def self.up Topic.find(:all).each do |topic| topic.destroy if topic.posts.count.zero? end end def self.down end end
Ruby
class TopicIndex < ActiveRecord::Migration def self.up add_index :topics, [:sticky, :replied_at], :name => :index_topics_on_sticky_and_replied_at end def self.down remove_index :topics, :name => :index_topics_on_sticky_and_replied_at end end
Ruby
class AddPostsUsersIndex < ActiveRecord::Migration def self.up remove_index "posts", :name => "index_posts_on_user_id" add_index "posts", ["user_id", "created_at"], :name => "index_posts_on_user_id" end def self.down remove_index "posts", :name => "index_posts_on_user_id" add_index "posts", ["use...
Ruby
class AddTopicLastPostedAtDate < ActiveRecord::Migration class Post < ActiveRecord::Base; end def self.up add_column "posts", "replied_at", :datetime Post.update_all 'replied_at = updated_at', 'topic_id = id' end def self.down remove_column "posts", "replied_at" end end
Ruby
class FixLastPosts < ActiveRecord::Migration class Topic < ActiveRecord::Base has_many :posts, :order => 'posts.created_at' end class Post < ActiveRecord::Base; end def self.up Topic.find(:all, :include => :posts).each do |topic| post = topic.posts.last Topic.transaction do Topic.u...
Ruby
class ReAddPostsForumId < ActiveRecord::Migration class Topic < ActiveRecord::Base; end class Post < ActiveRecord::Base; end def self.up add_column "posts", "forum_id", :integer Topic.find(:all, :select => 'id, forum_id').each do |t| Post.update_all ['forum_id = ?', t.forum_id], ['topic_id = ?', t....
Ruby
class FixRepliedAt < ActiveRecord::Migration def self.up execute 'update posts set replied_at=created_at where replied_at is null and id=topic_id' end def self.down end end
Ruby
class IndexHappy < ActiveRecord::Migration def self.up remove_index :posts, :name => :index_posts_on_topic_id add_index :posts, [:forum_id, :created_at], :name => :index_posts_on_forum_id add_index :users, :last_seen_at, :name => :index_users_on_last_seen_at add_index :moderatorships, :forum_id, :name...
Ruby
class RemoveUnusedUserProfile < ActiveRecord::Migration def self.up remove_column "users", "aim" remove_column "users", "yahoo" remove_column "users", "google_talk" remove_column "users", "msn" add_column "users", "bio", :string end def self.down add_column "users", "aim", ...
Ruby
class UserUpdatedAt < ActiveRecord::Migration def self.up add_column "users", "updated_at", :datetime end def self.down remove_column "users", "updated_at" end end
Ruby
class AddExceptionTable < ActiveRecord::Migration def self.up create_table "logged_exceptions", :force => true do |t| t.column :exception_class, :string t.column :controller_name, :string t.column :action_name, :string t.column :message, :string t.column :backtrace, ...
Ruby
class AddCounterCaches < ActiveRecord::Migration def self.up add_column "users", "topics_count", :integer, :default => 0 add_column "forums", "topics_count", :integer, :default => 0 add_column "forums", "posts_count", :integer, :default => 0 add_column "posts", "posts_count", :integer, :default =>...
Ruby
class ResetCounterCache < ActiveRecord::Migration def self.up Forum.find(:all).each do | forum | forum.topics_count=forum.topics.count forum.posts_count=forum.posts.count forum.save end Post.find(:all).each do | i | i.posts_count=i.posts.count i.save end Us...
Ruby
class RemoveUnnecessaryPostForumId < ActiveRecord::Migration def self.up remove_column :posts, :forum_id end def self.down add_column :posts, :forum_id, :integer end end
Ruby
class Sticky < ActiveRecord::Migration def self.up add_column "posts", "sticky", :boolean, :default => false end def self.down remove_column "posts", "sticky" end end
Ruby
class SetUserDisplayName < ActiveRecord::Migration class User < ActiveRecord::Base ; end def self.up User.find(:all, :select => 'id, login, display_name').each do |u| u.update_attribute :display_name, u.login if u.display_name.blank? end end def self.down end end
Ruby
class TopicsCacheLastRepliedUser < ActiveRecord::Migration class Post < ActiveRecord::Base; end class Topic < ActiveRecord::Base has_many :posts end def self.up add_column "topics", "replied_by", :integer add_column "topics", "last_post_id", :integer Topic.find(:all).each do |topic| next i...
Ruby
class AddForumDesc < ActiveRecord::Migration def self.up add_column "forums", "description", :string end def self.down remove_column "forums", "description" end end
Ruby
class AddSessions < ActiveRecord::Migration def self.up create_table :sessions do |t| t.column :session_id, :string t.column :data, :text t.column :updated_at, :datetime end add_index :sessions, :session_id end def self.down drop_table :sessions end end
Ruby
class UpdateWhiteList < ActiveRecord::Migration def self.up [Post, Forum, User].each do |klass| klass.transaction do klass.find(:all).each do |record| begin record.save_without_validation! rescue puts message_for_record(record, "[#{$!.class.name}] #{$!.mes...
Ruby
class AddUserIdentityUrl < ActiveRecord::Migration def self.up add_column "users", "identity_url", :string end def self.down remove_column "users", "identity_url" end end
Ruby
class SetLastSeenAt < ActiveRecord::Migration def self.up User.find(:all).each do |user| if user.last_seen_at.nil? user.last_seen_at=Time.now.utc user.save! end end end def self.down end end
Ruby
class PositionForForums < ActiveRecord::Migration def self.up add_column "forums", "position", :integer end def self.down remove_column "forums", "position" end end
Ruby
class CreateUsers < ActiveRecord::Migration def self.up create_table :users do |t| t.column :login, :string t.column :email, :string t.column :password, :string t.column :created_at, :datetime t.column :last_login_at, :datetime t.column :admin, :boolean t.column :posts_co...
Ruby
class AddActivatedBoolean < ActiveRecord::Migration class User < ActiveRecord::Base ; end def self.up add_column "users", "activated", :boolean, :default => false say_with_time("Activating all current users...") { User.update_all ['activated = ?', true] } end def self.down remove_column "users", "a...
Ruby
class UpdateUserPostCounts < ActiveRecord::Migration def self.up # old and not needed, we only need to know post count remove_column "users", "topics_count" # because i think the counts have been off User.find(:all).each do | i | i.posts_count=i.posts.count i.save end end def self...
Ruby
class RecentTopicsIndex < ActiveRecord::Migration def self.up # this index needed for when we get recent posts only and bypass the sticky bit # in that case the databaes would be unable to use the existing index add_index :topics, [:forum_id, :replied_at] end def self.down remove_index :topics, [...
Ruby
class RenamePostToTopic < ActiveRecord::Migration def self.up rename_column :posts, :post_id, :topic_id end def self.down rename_column :posts, :topic_id, :post_id end end
Ruby
class TopicLocked < ActiveRecord::Migration def self.up add_column "topics", "locked", :boolean, :default => false Topic.update_all [ "locked= ? ", false ] end def self.down remove_column "topics", "locked" end end
Ruby
class CreateModeratorships < ActiveRecord::Migration def self.up create_table :moderatorships do |t| t.column :forum_id, :integer t.column :user_id, :integer end end def self.down drop_table :moderatorships end end
Ruby
ENV["RAILS_ENV"] = "test" PASSWORD_SALT = 'beast' require File.expand_path(File.dirname(__FILE__) + "/../config/environment") require 'test_help' class Test::Unit::TestCase self.use_transactional_fixtures = true self.use_instantiated_fixtures = false def self.all_fixtures fixtures :forums, :users, :p...
Ruby
#!/opt/local/bin/ruby require File.dirname(__FILE__) + "/../config/environment" unless defined?(RAILS_ROOT) # If you're using RubyGems and mod_ruby, this require should be changed to an absolute path one, like: # "/usr/local/lib/ruby/gems/1.8/gems/rails-0.8.0/lib/dispatcher" -- otherwise performance is severely impai...
Ruby
#!/opt/local/bin/ruby # # You may specify the path to the FastCGI crash log (a log of unhandled # exceptions which forced the FastCGI instance to exit, great for debugging) # and the number of requests to process before running garbage collection. # # By default, the FastCGI crash log is RAILS_ROOT/log/fastcgi.crash.lo...
Ruby
#!/opt/local/bin/ruby require File.dirname(__FILE__) + "/../config/environment" unless defined?(RAILS_ROOT) # If you're using RubyGems and mod_ruby, this require should be changed to an absolute path one, like: # "/usr/local/lib/ruby/gems/1.8/gems/rails-0.8.0/lib/dispatcher" -- otherwise performance is severely impai...
Ruby
#!/opt/local/bin/ruby require File.dirname(__FILE__) + "/../config/environment" unless defined?(RAILS_ROOT) # If you're using RubyGems and mod_ruby, this require should be changed to an absolute path one, like: # "/usr/local/lib/ruby/gems/1.8/gems/rails-0.8.0/lib/dispatcher" -- otherwise performance is severely impai...
Ruby
#!/opt/local/bin/ruby # # You may specify the path to the FastCGI crash log (a log of unhandled # exceptions which forced the FastCGI instance to exit, great for debugging) # and the number of requests to process before running garbage collection. # # By default, the FastCGI crash log is RAILS_ROOT/log/fastcgi.crash.lo...
Ruby
#!/opt/local/bin/ruby require File.dirname(__FILE__) + "/../config/environment" unless defined?(RAILS_ROOT) # If you're using RubyGems and mod_ruby, this require should be changed to an absolute path one, like: # "/usr/local/lib/ruby/gems/1.8/gems/rails-0.8.0/lib/dispatcher" -- otherwise performance is severely impai...
Ruby
#!/usr/bin/env ruby require File.dirname(__FILE__) + '/../config/boot' require 'commands/breakpointer'
Ruby
#!/usr/bin/env ruby require File.dirname(__FILE__) + '/../config/boot' require 'commands/destroy'
Ruby
#!/usr/bin/env ruby require File.dirname(__FILE__) + '/../config/boot' require 'commands/about'
Ruby
#!/usr/bin/env ruby require File.dirname(__FILE__) + '/../config/boot' require 'commands/runner'
Ruby