diff options
author | Yehuda Katz + Carl Lerche <ykatz+clerche@engineyard.com> | 2009-09-24 14:01:31 -0700 |
---|---|---|
committer | Yehuda Katz + Carl Lerche <ykatz+clerche@engineyard.com> | 2009-09-24 16:11:41 -0700 |
commit | f0dd77c6be6a86fe384bb0015151e0a497973d39 (patch) | |
tree | ad81bb4c807c39edeaa37035882a16d9d95ebaa9 /railties/lib/generators/rails/metal | |
parent | 610b81beca461a6fa4f00c7023e0e4315eb2b8be (diff) | |
download | rails-f0dd77c6be6a86fe384bb0015151e0a497973d39.tar.gz rails-f0dd77c6be6a86fe384bb0015151e0a497973d39.tar.bz2 rails-f0dd77c6be6a86fe384bb0015151e0a497973d39.zip |
Move railties/lib/* into railties/lib/*
Diffstat (limited to 'railties/lib/generators/rails/metal')
-rw-r--r-- | railties/lib/generators/rails/metal/USAGE | 8 | ||||
-rw-r--r-- | railties/lib/generators/rails/metal/metal_generator.rb | 11 | ||||
-rw-r--r-- | railties/lib/generators/rails/metal/templates/metal.rb | 12 |
3 files changed, 0 insertions, 31 deletions
diff --git a/railties/lib/generators/rails/metal/USAGE b/railties/lib/generators/rails/metal/USAGE deleted file mode 100644 index 123ec6c03f..0000000000 --- a/railties/lib/generators/rails/metal/USAGE +++ /dev/null @@ -1,8 +0,0 @@ -Description: - Cast some metal! - -Examples: - `./script/generate metal poller` - - This will create: - Metal: app/metal/poller.rb diff --git a/railties/lib/generators/rails/metal/metal_generator.rb b/railties/lib/generators/rails/metal/metal_generator.rb deleted file mode 100644 index fe4f945cad..0000000000 --- a/railties/lib/generators/rails/metal/metal_generator.rb +++ /dev/null @@ -1,11 +0,0 @@ -module Rails - module Generators - class MetalGenerator < NamedBase - check_class_collision - - def create_metal_file - template "metal.rb", "app/metal/#{file_name}.rb" - end - end - end -end diff --git a/railties/lib/generators/rails/metal/templates/metal.rb b/railties/lib/generators/rails/metal/templates/metal.rb deleted file mode 100644 index e94982b69a..0000000000 --- a/railties/lib/generators/rails/metal/templates/metal.rb +++ /dev/null @@ -1,12 +0,0 @@ -# Allow the metal piece to run in isolation -require(File.dirname(__FILE__) + "/../../config/environment") unless defined?(Rails) - -class <%= class_name %> - def self.call(env) - if env["PATH_INFO"] =~ /^\/<%= file_name %>/ - [200, {"Content-Type" => "text/html"}, ["Hello, World!"]] - else - [404, {"Content-Type" => "text/html"}, ["Not Found"]] - end - end -end |