/instiki/svnpassword

To download this project, use:
bzr branch https://golem.ph.utexas.edu/~distler/code/instiki/svn/
1 by Jacques Distler
Checkout of Instiki Trunk 1/21/2007.
1 
#!/usr/bin/env ruby
2 
require 'optparse'
3 
4 
options = { :environment => "development" }
5 
6 
ARGV.options do |opts|
7 
 script_name = File.basename(0ドル)
8 
 opts.banner = "Usage: runner 'puts Person.find(1).name' [options]"
9 
10 
 opts.separator ""
11 
12 
 opts.on("-e", "--environment=name", String,
13 
 "Specifies the environment for the runner to operate under (test/development/production).",
14 
 "Default: development") { |options[:environment]| }
15 
16 
 opts.separator ""
17 
18 
 opts.on("-h", "--help",
19 
 "Show this help message.") { puts opts; exit }
20 
21 
 opts.parse!
22 
end
23 
24 
ENV["RAILS_ENV"] = options[:environment]
25 
26 
#!/usr/bin/env ruby
27 
28 
require File.dirname(__FILE__) + '/../config/environment'
29 
eval(ARGV.first)

AltStyle によって変換されたページ (->オリジナル) /