rails 2.3.18 → 7.1.3.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/MIT-LICENSE +2 -2
- data/README.md +97 -0
- metadata +207 -332
- data/CHANGELOG +0 -2193
- data/README +0 -243
- data/Rakefile +0 -365
- data/bin/about +0 -4
- data/bin/console +0 -3
- data/bin/dbconsole +0 -3
- data/bin/destroy +0 -3
- data/bin/generate +0 -3
- data/bin/performance/benchmarker +0 -3
- data/bin/performance/profiler +0 -3
- data/bin/plugin +0 -3
- data/bin/rails +0 -21
- data/bin/runner +0 -3
- data/bin/server +0 -3
- data/builtin/rails_info/rails/info.rb +0 -131
- data/builtin/rails_info/rails/info_controller.rb +0 -9
- data/builtin/rails_info/rails/info_helper.rb +0 -2
- data/builtin/rails_info/rails_info_controller.rb +0 -2
- data/configs/databases/frontbase.yml +0 -28
- data/configs/databases/ibm_db.yml +0 -62
- data/configs/databases/mysql.yml +0 -60
- data/configs/databases/oracle.yml +0 -39
- data/configs/databases/postgresql.yml +0 -51
- data/configs/databases/sqlite2.yml +0 -19
- data/configs/databases/sqlite3.yml +0 -22
- data/configs/empty.log +0 -0
- data/configs/initializers/backtrace_silencers.rb +0 -7
- data/configs/initializers/cookie_verification_secret.rb +0 -7
- data/configs/initializers/inflections.rb +0 -10
- data/configs/initializers/mime_types.rb +0 -5
- data/configs/initializers/new_rails_defaults.rb +0 -21
- data/configs/initializers/session_store.rb +0 -15
- data/configs/locales/en.yml +0 -5
- data/configs/routes.rb +0 -43
- data/configs/seeds.rb +0 -7
- data/dispatches/config.ru +0 -7
- data/dispatches/dispatch.fcgi +0 -24
- data/dispatches/dispatch.rb +0 -10
- data/dispatches/gateway.cgi +0 -97
- data/doc/README_FOR_APP +0 -2
- data/environments/boot.rb +0 -114
- data/environments/development.rb +0 -17
- data/environments/environment.rb +0 -41
- data/environments/production.rb +0 -28
- data/environments/test.rb +0 -28
- data/fresh_rakefile +0 -10
- data/helpers/application_controller.rb +0 -10
- data/helpers/application_helper.rb +0 -3
- data/helpers/performance_test.rb +0 -9
- data/helpers/test_helper.rb +0 -38
- data/html/404.html +0 -30
- data/html/422.html +0 -30
- data/html/500.html +0 -30
- data/html/favicon.ico +0 -0
- data/html/images/rails.png +0 -0
- data/html/index.html +0 -275
- data/html/javascripts/application.js +0 -2
- data/html/javascripts/controls.js +0 -963
- data/html/javascripts/dragdrop.js +0 -973
- data/html/javascripts/effects.js +0 -1128
- data/html/javascripts/prototype.js +0 -4320
- data/html/robots.txt +0 -5
- data/lib/code_statistics.rb +0 -107
- data/lib/commands/about.rb +0 -3
- data/lib/commands/console.rb +0 -45
- data/lib/commands/dbconsole.rb +0 -87
- data/lib/commands/destroy.rb +0 -6
- data/lib/commands/generate.rb +0 -6
- data/lib/commands/ncgi/listener +0 -86
- data/lib/commands/ncgi/tracker +0 -69
- data/lib/commands/performance/benchmarker.rb +0 -24
- data/lib/commands/performance/profiler.rb +0 -50
- data/lib/commands/plugin.rb +0 -968
- data/lib/commands/runner.rb +0 -54
- data/lib/commands/server.rb +0 -114
- data/lib/commands/update.rb +0 -4
- data/lib/commands.rb +0 -17
- data/lib/console_app.rb +0 -30
- data/lib/console_sandbox.rb +0 -6
- data/lib/console_with_helpers.rb +0 -5
- data/lib/dispatcher.rb +0 -24
- data/lib/fcgi_handler.rb +0 -239
- data/lib/initializer.rb +0 -1152
- data/lib/performance_test_help.rb +0 -5
- data/lib/rails/backtrace_cleaner.rb +0 -54
- data/lib/rails/gem_builder.rb +0 -21
- data/lib/rails/gem_dependency.rb +0 -317
- data/lib/rails/plugin/loader.rb +0 -198
- data/lib/rails/plugin/locator.rb +0 -100
- data/lib/rails/plugin.rb +0 -179
- data/lib/rails/rack/debugger.rb +0 -23
- data/lib/rails/rack/log_tailer.rb +0 -35
- data/lib/rails/rack/metal.rb +0 -51
- data/lib/rails/rack/static.rb +0 -46
- data/lib/rails/rack.rb +0 -8
- data/lib/rails/vendor_gem_source_index.rb +0 -140
- data/lib/rails/version.rb +0 -9
- data/lib/rails_generator/base.rb +0 -266
- data/lib/rails_generator/commands.rb +0 -621
- data/lib/rails_generator/generated_attribute.rb +0 -47
- data/lib/rails_generator/generators/applications/app/USAGE +0 -9
- data/lib/rails_generator/generators/applications/app/app_generator.rb +0 -266
- data/lib/rails_generator/generators/applications/app/scm/git.rb +0 -18
- data/lib/rails_generator/generators/applications/app/scm/scm.rb +0 -8
- data/lib/rails_generator/generators/applications/app/scm/svn.rb +0 -7
- data/lib/rails_generator/generators/applications/app/template_runner.rb +0 -401
- data/lib/rails_generator/generators/components/controller/USAGE +0 -30
- data/lib/rails_generator/generators/components/controller/controller_generator.rb +0 -43
- data/lib/rails_generator/generators/components/controller/templates/controller.rb +0 -7
- data/lib/rails_generator/generators/components/controller/templates/functional_test.rb +0 -8
- data/lib/rails_generator/generators/components/controller/templates/helper.rb +0 -2
- data/lib/rails_generator/generators/components/controller/templates/helper_test.rb +0 -4
- data/lib/rails_generator/generators/components/controller/templates/view.html.erb +0 -2
- data/lib/rails_generator/generators/components/helper/USAGE +0 -24
- data/lib/rails_generator/generators/components/helper/helper_generator.rb +0 -25
- data/lib/rails_generator/generators/components/helper/templates/helper.rb +0 -2
- data/lib/rails_generator/generators/components/helper/templates/helper_test.rb +0 -4
- data/lib/rails_generator/generators/components/integration_test/USAGE +0 -8
- data/lib/rails_generator/generators/components/integration_test/integration_test_generator.rb +0 -16
- data/lib/rails_generator/generators/components/integration_test/templates/integration_test.rb +0 -10
- data/lib/rails_generator/generators/components/mailer/USAGE +0 -16
- data/lib/rails_generator/generators/components/mailer/mailer_generator.rb +0 -30
- data/lib/rails_generator/generators/components/mailer/templates/fixture.erb +0 -3
- data/lib/rails_generator/generators/components/mailer/templates/fixture.rhtml +0 -0
- data/lib/rails_generator/generators/components/mailer/templates/mailer.rb +0 -15
- data/lib/rails_generator/generators/components/mailer/templates/unit_test.rb +0 -20
- data/lib/rails_generator/generators/components/mailer/templates/view.erb +0 -3
- data/lib/rails_generator/generators/components/mailer/templates/view.rhtml +0 -0
- data/lib/rails_generator/generators/components/metal/USAGE +0 -8
- data/lib/rails_generator/generators/components/metal/metal_generator.rb +0 -8
- data/lib/rails_generator/generators/components/metal/templates/metal.rb +0 -12
- data/lib/rails_generator/generators/components/migration/USAGE +0 -29
- data/lib/rails_generator/generators/components/migration/migration_generator.rb +0 -20
- data/lib/rails_generator/generators/components/migration/templates/migration.rb +0 -11
- data/lib/rails_generator/generators/components/model/USAGE +0 -27
- data/lib/rails_generator/generators/components/model/model_generator.rb +0 -52
- data/lib/rails_generator/generators/components/model/templates/fixtures.yml +0 -23
- data/lib/rails_generator/generators/components/model/templates/migration.rb +0 -16
- data/lib/rails_generator/generators/components/model/templates/model.rb +0 -5
- data/lib/rails_generator/generators/components/model/templates/unit_test.rb +0 -8
- data/lib/rails_generator/generators/components/observer/USAGE +0 -13
- data/lib/rails_generator/generators/components/observer/observer_generator.rb +0 -16
- data/lib/rails_generator/generators/components/observer/templates/observer.rb +0 -2
- data/lib/rails_generator/generators/components/observer/templates/unit_test.rb +0 -8
- data/lib/rails_generator/generators/components/performance_test/USAGE +0 -8
- data/lib/rails_generator/generators/components/performance_test/performance_test_generator.rb +0 -16
- data/lib/rails_generator/generators/components/performance_test/templates/performance_test.rb +0 -9
- data/lib/rails_generator/generators/components/plugin/USAGE +0 -25
- data/lib/rails_generator/generators/components/plugin/plugin_generator.rb +0 -39
- data/lib/rails_generator/generators/components/plugin/templates/MIT-LICENSE +0 -20
- data/lib/rails_generator/generators/components/plugin/templates/README +0 -13
- data/lib/rails_generator/generators/components/plugin/templates/Rakefile +0 -23
- data/lib/rails_generator/generators/components/plugin/templates/USAGE +0 -8
- data/lib/rails_generator/generators/components/plugin/templates/generator.rb +0 -8
- data/lib/rails_generator/generators/components/plugin/templates/init.rb +0 -1
- data/lib/rails_generator/generators/components/plugin/templates/install.rb +0 -1
- data/lib/rails_generator/generators/components/plugin/templates/plugin.rb +0 -1
- data/lib/rails_generator/generators/components/plugin/templates/tasks.rake +0 -4
- data/lib/rails_generator/generators/components/plugin/templates/test_helper.rb +0 -4
- data/lib/rails_generator/generators/components/plugin/templates/uninstall.rb +0 -1
- data/lib/rails_generator/generators/components/plugin/templates/unit_test.rb +0 -8
- data/lib/rails_generator/generators/components/resource/USAGE +0 -23
- data/lib/rails_generator/generators/components/resource/resource_generator.rb +0 -76
- data/lib/rails_generator/generators/components/resource/templates/controller.rb +0 -2
- data/lib/rails_generator/generators/components/resource/templates/functional_test.rb +0 -8
- data/lib/rails_generator/generators/components/resource/templates/helper.rb +0 -2
- data/lib/rails_generator/generators/components/resource/templates/helper_test.rb +0 -4
- data/lib/rails_generator/generators/components/scaffold/USAGE +0 -29
- data/lib/rails_generator/generators/components/scaffold/scaffold_generator.rb +0 -103
- data/lib/rails_generator/generators/components/scaffold/templates/controller.rb +0 -83
- data/lib/rails_generator/generators/components/scaffold/templates/functional_test.rb +0 -45
- data/lib/rails_generator/generators/components/scaffold/templates/helper.rb +0 -2
- data/lib/rails_generator/generators/components/scaffold/templates/helper_test.rb +0 -4
- data/lib/rails_generator/generators/components/scaffold/templates/layout.html.erb +0 -17
- data/lib/rails_generator/generators/components/scaffold/templates/style.css +0 -54
- data/lib/rails_generator/generators/components/scaffold/templates/view_edit.html.erb +0 -18
- data/lib/rails_generator/generators/components/scaffold/templates/view_index.html.erb +0 -24
- data/lib/rails_generator/generators/components/scaffold/templates/view_new.html.erb +0 -17
- data/lib/rails_generator/generators/components/scaffold/templates/view_show.html.erb +0 -10
- data/lib/rails_generator/generators/components/session_migration/USAGE +0 -10
- data/lib/rails_generator/generators/components/session_migration/session_migration_generator.rb +0 -18
- data/lib/rails_generator/generators/components/session_migration/templates/migration.rb +0 -16
- data/lib/rails_generator/lookup.rb +0 -249
- data/lib/rails_generator/manifest.rb +0 -53
- data/lib/rails_generator/options.rb +0 -150
- data/lib/rails_generator/scripts/destroy.rb +0 -29
- data/lib/rails_generator/scripts/generate.rb +0 -7
- data/lib/rails_generator/scripts/update.rb +0 -12
- data/lib/rails_generator/scripts.rb +0 -89
- data/lib/rails_generator/secret_key_generator.rb +0 -24
- data/lib/rails_generator/simple_logger.rb +0 -46
- data/lib/rails_generator/spec.rb +0 -44
- data/lib/rails_generator.rb +0 -46
- data/lib/railties_path.rb +0 -1
- data/lib/ruby_version_check.rb +0 -17
- data/lib/rubyprof_ext.rb +0 -35
- data/lib/source_annotation_extractor.rb +0 -102
- data/lib/tasks/annotations.rake +0 -20
- data/lib/tasks/databases.rake +0 -436
- data/lib/tasks/documentation.rake +0 -93
- data/lib/tasks/framework.rake +0 -146
- data/lib/tasks/gems.rake +0 -78
- data/lib/tasks/log.rake +0 -9
- data/lib/tasks/middleware.rake +0 -7
- data/lib/tasks/misc.rake +0 -63
- data/lib/tasks/rails.rb +0 -14
- data/lib/tasks/routes.rake +0 -18
- data/lib/tasks/statistics.rake +0 -17
- data/lib/tasks/testing.rake +0 -139
- data/lib/tasks/tmp.rake +0 -37
- data/lib/test_help.rb +0 -38
- data/lib/webrick_server.rb +0 -156
- data/railties.gemspec +0 -22
data/dispatches/gateway.cgi
DELETED
@@ -1,97 +0,0 @@
|
|
1
|
-
#!/usr/bin/env ruby
|
2
|
-
|
3
|
-
require 'drb'
|
4
|
-
|
5
|
-
# This file includes an experimental gateway CGI implementation. It will work
|
6
|
-
# only on platforms which support both fork and sockets.
|
7
|
-
#
|
8
|
-
# To enable it edit public/.htaccess and replace dispatch.cgi with gateway.cgi.
|
9
|
-
#
|
10
|
-
# Next, create the directory log/drb_gateway and grant the apache user rw access
|
11
|
-
# to said directory.
|
12
|
-
#
|
13
|
-
# On the next request to your server, the gateway tracker should start up, along
|
14
|
-
# with a few listener processes. This setup should provide you with much better
|
15
|
-
# speeds than dispatch.cgi.
|
16
|
-
#
|
17
|
-
# Keep in mind that the first request made to the server will be slow, as the
|
18
|
-
# tracker and listeners will have to load. Also, the tracker and listeners will
|
19
|
-
# shutdown after a period if inactivity. You can set this value below -- the
|
20
|
-
# default is 90 seconds.
|
21
|
-
|
22
|
-
TrackerSocket = File.expand_path(File.join(File.dirname(__FILE__), '../log/drb_gateway/tracker.sock'))
|
23
|
-
DieAfter = 90 # Seconds
|
24
|
-
Listeners = 3
|
25
|
-
|
26
|
-
def message(s)
|
27
|
-
$stderr.puts "gateway.cgi: #{s}" if ENV && ENV["DEBUG_GATEWAY"]
|
28
|
-
end
|
29
|
-
|
30
|
-
def listener_socket(number)
|
31
|
-
File.expand_path(File.join(File.dirname(__FILE__), "../log/drb_gateway/listener_#{number}.sock"))
|
32
|
-
end
|
33
|
-
|
34
|
-
unless File.exist? TrackerSocket
|
35
|
-
message "Starting tracker and #{Listeners} listeners"
|
36
|
-
fork do
|
37
|
-
Process.setsid
|
38
|
-
STDIN.reopen "/dev/null"
|
39
|
-
STDOUT.reopen "/dev/null", "a"
|
40
|
-
|
41
|
-
root = File.expand_path(File.dirname(__FILE__) + '/..')
|
42
|
-
|
43
|
-
message "starting tracker"
|
44
|
-
fork do
|
45
|
-
ARGV.clear
|
46
|
-
ARGV << TrackerSocket << Listeners.to_s << DieAfter.to_s
|
47
|
-
load File.join(root, 'script', 'tracker')
|
48
|
-
end
|
49
|
-
|
50
|
-
message "starting listeners"
|
51
|
-
require File.join(root, 'config/environment.rb')
|
52
|
-
Listeners.times do |number|
|
53
|
-
fork do
|
54
|
-
ARGV.clear
|
55
|
-
ARGV << listener_socket(number) << DieAfter.to_s
|
56
|
-
load File.join(root, 'script', 'listener')
|
57
|
-
end
|
58
|
-
end
|
59
|
-
end
|
60
|
-
|
61
|
-
message "waiting for tracker and listener to arise..."
|
62
|
-
ready = false
|
63
|
-
10.times do
|
64
|
-
sleep 0.5
|
65
|
-
break if (ready = File.exist?(TrackerSocket) && File.exist?(listener_socket(0)))
|
66
|
-
end
|
67
|
-
|
68
|
-
if ready
|
69
|
-
message "tracker and listener are ready"
|
70
|
-
else
|
71
|
-
message "Waited 5 seconds, listener and tracker not ready... dropping request"
|
72
|
-
Kernel.exit 1
|
73
|
-
end
|
74
|
-
end
|
75
|
-
|
76
|
-
DRb.start_service
|
77
|
-
|
78
|
-
message "connecting to tracker"
|
79
|
-
tracker = DRbObject.new_with_uri("drbunix:#{TrackerSocket}")
|
80
|
-
|
81
|
-
input = $stdin.read
|
82
|
-
$stdin.close
|
83
|
-
|
84
|
-
env = ENV.inspect
|
85
|
-
|
86
|
-
output = nil
|
87
|
-
tracker.with_listener do |number|
|
88
|
-
message "connecting to listener #{number}"
|
89
|
-
socket = listener_socket(number)
|
90
|
-
listener = DRbObject.new_with_uri("drbunix:#{socket}")
|
91
|
-
output = listener.process(env, input)
|
92
|
-
message "listener #{number} has finished, writing output"
|
93
|
-
end
|
94
|
-
|
95
|
-
$stdout.write output
|
96
|
-
$stdout.flush
|
97
|
-
$stdout.close
|
data/doc/README_FOR_APP
DELETED
data/environments/boot.rb
DELETED
@@ -1,114 +0,0 @@
|
|
1
|
-
# Don't change this file!
|
2
|
-
# Configure your app in config/environment.rb and config/environments/*.rb
|
3
|
-
|
4
|
-
RAILS_ROOT = "#{File.dirname(__FILE__)}/.." unless defined?(RAILS_ROOT)
|
5
|
-
|
6
|
-
module Rails
|
7
|
-
class << self
|
8
|
-
def boot!
|
9
|
-
unless booted?
|
10
|
-
preinitialize
|
11
|
-
pick_boot.run
|
12
|
-
end
|
13
|
-
end
|
14
|
-
|
15
|
-
def booted?
|
16
|
-
defined? Rails::Initializer
|
17
|
-
end
|
18
|
-
|
19
|
-
def pick_boot
|
20
|
-
(vendor_rails? ? VendorBoot : GemBoot).new
|
21
|
-
end
|
22
|
-
|
23
|
-
def vendor_rails?
|
24
|
-
File.exist?("#{RAILS_ROOT}/vendor/rails")
|
25
|
-
end
|
26
|
-
|
27
|
-
def preinitialize
|
28
|
-
load(preinitializer_path) if File.exist?(preinitializer_path)
|
29
|
-
end
|
30
|
-
|
31
|
-
def preinitializer_path
|
32
|
-
"#{RAILS_ROOT}/config/preinitializer.rb"
|
33
|
-
end
|
34
|
-
end
|
35
|
-
|
36
|
-
class Boot
|
37
|
-
def run
|
38
|
-
load_initializer
|
39
|
-
Rails::Initializer.run(:set_load_path)
|
40
|
-
end
|
41
|
-
end
|
42
|
-
|
43
|
-
class VendorBoot < Boot
|
44
|
-
def load_initializer
|
45
|
-
require "#{RAILS_ROOT}/vendor/rails/railties/lib/initializer"
|
46
|
-
Rails::Initializer.run(:install_gem_spec_stubs)
|
47
|
-
Rails::GemDependency.add_frozen_gem_path
|
48
|
-
end
|
49
|
-
end
|
50
|
-
|
51
|
-
class GemBoot < Boot
|
52
|
-
def load_initializer
|
53
|
-
self.class.load_rubygems
|
54
|
-
load_rails_gem
|
55
|
-
require 'initializer'
|
56
|
-
end
|
57
|
-
|
58
|
-
def load_rails_gem
|
59
|
-
if version = self.class.gem_version
|
60
|
-
gem 'rails', version
|
61
|
-
else
|
62
|
-
gem 'rails'
|
63
|
-
end
|
64
|
-
rescue Gem::LoadError => load_error
|
65
|
-
if load_error.message =~ /Could not find RubyGem rails/
|
66
|
-
STDERR.puts %(Missing the Rails #{version} gem. Please `gem install -v=#{version} rails`, update your RAILS_GEM_VERSION setting in config/environment.rb for the Rails version you do have installed, or comment out RAILS_GEM_VERSION to use the latest version installed.)
|
67
|
-
exit 1
|
68
|
-
else
|
69
|
-
raise
|
70
|
-
end
|
71
|
-
end
|
72
|
-
|
73
|
-
class << self
|
74
|
-
def rubygems_version
|
75
|
-
Gem::RubyGemsVersion rescue nil
|
76
|
-
end
|
77
|
-
|
78
|
-
def gem_version
|
79
|
-
if defined? RAILS_GEM_VERSION
|
80
|
-
RAILS_GEM_VERSION
|
81
|
-
elsif ENV.include?('RAILS_GEM_VERSION')
|
82
|
-
ENV['RAILS_GEM_VERSION']
|
83
|
-
else
|
84
|
-
parse_gem_version(read_environment_rb)
|
85
|
-
end
|
86
|
-
end
|
87
|
-
|
88
|
-
def load_rubygems
|
89
|
-
min_version = '1.3.2'
|
90
|
-
require 'rubygems'
|
91
|
-
unless rubygems_version >= min_version
|
92
|
-
$stderr.puts %Q(Rails requires RubyGems >= #{min_version} (you have #{rubygems_version}). Please `gem update --system` and try again.)
|
93
|
-
exit 1
|
94
|
-
end
|
95
|
-
|
96
|
-
rescue LoadError
|
97
|
-
$stderr.puts %Q(Rails requires RubyGems >= #{min_version}. Please install RubyGems and try again: http://rubygems.rubyforge.org)
|
98
|
-
exit 1
|
99
|
-
end
|
100
|
-
|
101
|
-
def parse_gem_version(text)
|
102
|
-
$1 if text =~ /^[^#]*RAILS_GEM_VERSION\s*=\s*["']([!~<>=]*\s*[\d.]+)["']/
|
103
|
-
end
|
104
|
-
|
105
|
-
private
|
106
|
-
def read_environment_rb
|
107
|
-
File.read("#{RAILS_ROOT}/config/environment.rb")
|
108
|
-
end
|
109
|
-
end
|
110
|
-
end
|
111
|
-
end
|
112
|
-
|
113
|
-
# All that for this:
|
114
|
-
Rails.boot!
|
data/environments/development.rb
DELETED
@@ -1,17 +0,0 @@
|
|
1
|
-
# Settings specified here will take precedence over those in config/environment.rb
|
2
|
-
|
3
|
-
# In the development environment your application's code is reloaded on
|
4
|
-
# every request. This slows down response time but is perfect for development
|
5
|
-
# since you don't have to restart the webserver when you make code changes.
|
6
|
-
config.cache_classes = false
|
7
|
-
|
8
|
-
# Log error messages when you accidentally call methods on nil.
|
9
|
-
config.whiny_nils = true
|
10
|
-
|
11
|
-
# Show full error reports and disable caching
|
12
|
-
config.action_controller.consider_all_requests_local = true
|
13
|
-
config.action_view.debug_rjs = true
|
14
|
-
config.action_controller.perform_caching = false
|
15
|
-
|
16
|
-
# Don't care if the mailer can't send
|
17
|
-
config.action_mailer.raise_delivery_errors = false
|
data/environments/environment.rb
DELETED
@@ -1,41 +0,0 @@
|
|
1
|
-
# Be sure to restart your server when you modify this file
|
2
|
-
|
3
|
-
# Specifies gem version of Rails to use when vendor/rails is not present
|
4
|
-
<%= '# ' if freeze %>RAILS_GEM_VERSION = '<%= Rails::VERSION::STRING %>' unless defined? RAILS_GEM_VERSION
|
5
|
-
|
6
|
-
# Bootstrap the Rails environment, frameworks, and default configuration
|
7
|
-
require File.join(File.dirname(__FILE__), 'boot')
|
8
|
-
|
9
|
-
Rails::Initializer.run do |config|
|
10
|
-
# Settings in config/environments/* take precedence over those specified here.
|
11
|
-
# Application configuration should go into files in config/initializers
|
12
|
-
# -- all .rb files in that directory are automatically loaded.
|
13
|
-
|
14
|
-
# Add additional load paths for your own custom dirs
|
15
|
-
# config.autoload_paths += %W( #{RAILS_ROOT}/extras )
|
16
|
-
|
17
|
-
# Specify gems that this application depends on and have them installed with rake gems:install
|
18
|
-
# config.gem "bj"
|
19
|
-
# config.gem "hpricot", :version => '0.6', :source => "http://code.whytheluckystiff.net"
|
20
|
-
# config.gem "sqlite3-ruby", :lib => "sqlite3"
|
21
|
-
# config.gem "aws-s3", :lib => "aws/s3"
|
22
|
-
|
23
|
-
# Only load the plugins named here, in the order given (default is alphabetical).
|
24
|
-
# :all can be used as a placeholder for all plugins not explicitly named
|
25
|
-
# config.plugins = [ :exception_notification, :ssl_requirement, :all ]
|
26
|
-
|
27
|
-
# Skip frameworks you're not going to use. To use Rails without a database,
|
28
|
-
# you must remove the Active Record framework.
|
29
|
-
# config.frameworks -= [ :active_record, :active_resource, :action_mailer ]
|
30
|
-
|
31
|
-
# Activate observers that should always be running
|
32
|
-
# config.active_record.observers = :cacher, :garbage_collector, :forum_observer
|
33
|
-
|
34
|
-
# Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.
|
35
|
-
# Run "rake -D time" for a list of tasks for finding time zone names.
|
36
|
-
config.time_zone = 'UTC'
|
37
|
-
|
38
|
-
# The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
|
39
|
-
# config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}')]
|
40
|
-
# config.i18n.default_locale = :de
|
41
|
-
end
|
data/environments/production.rb
DELETED
@@ -1,28 +0,0 @@
|
|
1
|
-
# Settings specified here will take precedence over those in config/environment.rb
|
2
|
-
|
3
|
-
# The production environment is meant for finished, "live" apps.
|
4
|
-
# Code is not reloaded between requests
|
5
|
-
config.cache_classes = true
|
6
|
-
|
7
|
-
# Full error reports are disabled and caching is turned on
|
8
|
-
config.action_controller.consider_all_requests_local = false
|
9
|
-
config.action_controller.perform_caching = true
|
10
|
-
config.action_view.cache_template_loading = true
|
11
|
-
|
12
|
-
# See everything in the log (default is :info)
|
13
|
-
# config.log_level = :debug
|
14
|
-
|
15
|
-
# Use a different logger for distributed setups
|
16
|
-
# config.logger = SyslogLogger.new
|
17
|
-
|
18
|
-
# Use a different cache store in production
|
19
|
-
# config.cache_store = :mem_cache_store
|
20
|
-
|
21
|
-
# Enable serving of images, stylesheets, and javascripts from an asset server
|
22
|
-
# config.action_controller.asset_host = "http://assets.example.com"
|
23
|
-
|
24
|
-
# Disable delivery errors, bad email addresses will be ignored
|
25
|
-
# config.action_mailer.raise_delivery_errors = false
|
26
|
-
|
27
|
-
# Enable threaded mode
|
28
|
-
# config.threadsafe!
|
data/environments/test.rb
DELETED
@@ -1,28 +0,0 @@
|
|
1
|
-
# Settings specified here will take precedence over those in config/environment.rb
|
2
|
-
|
3
|
-
# The test environment is used exclusively to run your application's
|
4
|
-
# test suite. You never need to work with it otherwise. Remember that
|
5
|
-
# your test database is "scratch space" for the test suite and is wiped
|
6
|
-
# and recreated between test runs. Don't rely on the data there!
|
7
|
-
config.cache_classes = true
|
8
|
-
|
9
|
-
# Log error messages when you accidentally call methods on nil.
|
10
|
-
config.whiny_nils = true
|
11
|
-
|
12
|
-
# Show full error reports and disable caching
|
13
|
-
config.action_controller.consider_all_requests_local = true
|
14
|
-
config.action_controller.perform_caching = false
|
15
|
-
config.action_view.cache_template_loading = true
|
16
|
-
|
17
|
-
# Disable request forgery protection in test environment
|
18
|
-
config.action_controller.allow_forgery_protection = false
|
19
|
-
|
20
|
-
# Tell Action Mailer not to deliver emails to the real world.
|
21
|
-
# The :test delivery method accumulates sent emails in the
|
22
|
-
# ActionMailer::Base.deliveries array.
|
23
|
-
config.action_mailer.delivery_method = :test
|
24
|
-
|
25
|
-
# Use SQL instead of Active Record's schema dumper when creating the test database.
|
26
|
-
# This is necessary if your schema can't be completely dumped by the schema dumper,
|
27
|
-
# like if you have constraints or database-specific column types
|
28
|
-
# config.active_record.schema_format = :sql
|
data/fresh_rakefile
DELETED
@@ -1,10 +0,0 @@
|
|
1
|
-
# Add your own tasks in files placed in lib/tasks ending in .rake,
|
2
|
-
# for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.
|
3
|
-
|
4
|
-
require(File.join(File.dirname(__FILE__), 'config', 'boot'))
|
5
|
-
|
6
|
-
require 'rake'
|
7
|
-
require 'rake/testtask'
|
8
|
-
require 'rake/rdoctask'
|
9
|
-
|
10
|
-
require 'tasks/rails'
|
@@ -1,10 +0,0 @@
|
|
1
|
-
# Filters added to this controller apply to all controllers in the application.
|
2
|
-
# Likewise, all the methods added will be available for all controllers.
|
3
|
-
|
4
|
-
class ApplicationController < ActionController::Base
|
5
|
-
helper :all # include all helpers, all the time
|
6
|
-
protect_from_forgery # See ActionController::RequestForgeryProtection for details
|
7
|
-
|
8
|
-
# Scrub sensitive parameters from your log
|
9
|
-
# filter_parameter_logging :password
|
10
|
-
end
|
data/helpers/performance_test.rb
DELETED
data/helpers/test_helper.rb
DELETED
@@ -1,38 +0,0 @@
|
|
1
|
-
ENV["RAILS_ENV"] = "test"
|
2
|
-
require File.expand_path(File.dirname(__FILE__) + "/../config/environment")
|
3
|
-
require 'test_help'
|
4
|
-
|
5
|
-
class ActiveSupport::TestCase
|
6
|
-
# Transactional fixtures accelerate your tests by wrapping each test method
|
7
|
-
# in a transaction that's rolled back on completion. This ensures that the
|
8
|
-
# test database remains unchanged so your fixtures don't have to be reloaded
|
9
|
-
# between every test method. Fewer database queries means faster tests.
|
10
|
-
#
|
11
|
-
# Read Mike Clark's excellent walkthrough at
|
12
|
-
# http://clarkware.com/cgi/blosxom/2005/10/24#Rails10FastTesting
|
13
|
-
#
|
14
|
-
# Every Active Record database supports transactions except MyISAM tables
|
15
|
-
# in MySQL. Turn off transactional fixtures in this case; however, if you
|
16
|
-
# don't care one way or the other, switching from MyISAM to InnoDB tables
|
17
|
-
# is recommended.
|
18
|
-
#
|
19
|
-
# The only drawback to using transactional fixtures is when you actually
|
20
|
-
# need to test transactions. Since your test is bracketed by a transaction,
|
21
|
-
# any transactions started in your code will be automatically rolled back.
|
22
|
-
self.use_transactional_fixtures = true
|
23
|
-
|
24
|
-
# Instantiated fixtures are slow, but give you @david where otherwise you
|
25
|
-
# would need people(:david). If you don't want to migrate your existing
|
26
|
-
# test cases which use the @david style and don't mind the speed hit (each
|
27
|
-
# instantiated fixtures translates to a database query per test method),
|
28
|
-
# then set this back to true.
|
29
|
-
self.use_instantiated_fixtures = false
|
30
|
-
|
31
|
-
# Setup all fixtures in test/fixtures/*.(yml|csv) for all tests in alphabetical order.
|
32
|
-
#
|
33
|
-
# Note: You'll currently still have to declare fixtures explicitly in integration tests
|
34
|
-
# -- they do not yet inherit this setting
|
35
|
-
fixtures :all
|
36
|
-
|
37
|
-
# Add more helper methods to be used by all tests here...
|
38
|
-
end
|
data/html/404.html
DELETED
@@ -1,30 +0,0 @@
|
|
1
|
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
2
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
3
|
-
|
4
|
-
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
5
|
-
|
6
|
-
<head>
|
7
|
-
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
|
8
|
-
<title>The page you were looking for doesn't exist (404)</title>
|
9
|
-
<style type="text/css">
|
10
|
-
body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
|
11
|
-
div.dialog {
|
12
|
-
width: 25em;
|
13
|
-
padding: 0 4em;
|
14
|
-
margin: 4em auto 0 auto;
|
15
|
-
border: 1px solid #ccc;
|
16
|
-
border-right-color: #999;
|
17
|
-
border-bottom-color: #999;
|
18
|
-
}
|
19
|
-
h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
|
20
|
-
</style>
|
21
|
-
</head>
|
22
|
-
|
23
|
-
<body>
|
24
|
-
<!-- This file lives in public/404.html -->
|
25
|
-
<div class="dialog">
|
26
|
-
<h1>The page you were looking for doesn't exist.</h1>
|
27
|
-
<p>You may have mistyped the address or the page may have moved.</p>
|
28
|
-
</div>
|
29
|
-
</body>
|
30
|
-
</html>
|
data/html/422.html
DELETED
@@ -1,30 +0,0 @@
|
|
1
|
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
2
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
3
|
-
|
4
|
-
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
5
|
-
|
6
|
-
<head>
|
7
|
-
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
|
8
|
-
<title>The change you wanted was rejected (422)</title>
|
9
|
-
<style type="text/css">
|
10
|
-
body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
|
11
|
-
div.dialog {
|
12
|
-
width: 25em;
|
13
|
-
padding: 0 4em;
|
14
|
-
margin: 4em auto 0 auto;
|
15
|
-
border: 1px solid #ccc;
|
16
|
-
border-right-color: #999;
|
17
|
-
border-bottom-color: #999;
|
18
|
-
}
|
19
|
-
h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
|
20
|
-
</style>
|
21
|
-
</head>
|
22
|
-
|
23
|
-
<body>
|
24
|
-
<!-- This file lives in public/422.html -->
|
25
|
-
<div class="dialog">
|
26
|
-
<h1>The change you wanted was rejected.</h1>
|
27
|
-
<p>Maybe you tried to change something you didn't have access to.</p>
|
28
|
-
</div>
|
29
|
-
</body>
|
30
|
-
</html>
|
data/html/500.html
DELETED
@@ -1,30 +0,0 @@
|
|
1
|
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
2
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
3
|
-
|
4
|
-
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
5
|
-
|
6
|
-
<head>
|
7
|
-
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
|
8
|
-
<title>We're sorry, but something went wrong (500)</title>
|
9
|
-
<style type="text/css">
|
10
|
-
body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
|
11
|
-
div.dialog {
|
12
|
-
width: 25em;
|
13
|
-
padding: 0 4em;
|
14
|
-
margin: 4em auto 0 auto;
|
15
|
-
border: 1px solid #ccc;
|
16
|
-
border-right-color: #999;
|
17
|
-
border-bottom-color: #999;
|
18
|
-
}
|
19
|
-
h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
|
20
|
-
</style>
|
21
|
-
</head>
|
22
|
-
|
23
|
-
<body>
|
24
|
-
<!-- This file lives in public/500.html -->
|
25
|
-
<div class="dialog">
|
26
|
-
<h1>We're sorry, but something went wrong.</h1>
|
27
|
-
<p>We've been notified about this issue and we'll take a look at it shortly.</p>
|
28
|
-
</div>
|
29
|
-
</body>
|
30
|
-
</html>
|
data/html/favicon.ico
DELETED
File without changes
|
data/html/images/rails.png
DELETED
Binary file
|