Permalink
Browse files

right place for the rails' rake task

  • Loading branch information...
1 parent 3fae618 commit ad2617a869ac2be8ed07485f407044c9eccd8ab6 @nicooga committed Jan 13, 2012
View
@@ -140,7 +140,7 @@ desc "Validate #{gemspec_file}"
task :validate do
libfiles = Dir['lib/*'] - ["lib/#{name}.rb", "lib/#{name}"]
unless libfiles.empty?
- puts "Directory `lib` should only contain a `#{name}.rb` file and `#{name}` dir."
+ puts "Directory `lib` should only contain a `#{name}.rb` file and a `#{name}` dir."
exit!
end
unless Dir['VERSION*'].empty?
View
@@ -18,7 +18,7 @@ Gem::Specification.new do |s|
s.require_paths = %w[lib]
s.rdoc_options = ["--charset=UTF-8"]
- s.extra_rdoc_files = %w[README.md LICENSE tasks]
+ s.extra_rdoc_files = %w[README.md LICENSE]
# = MANIFEST =
s.files = %w[
@@ -27,6 +27,8 @@ Gem::Specification.new do |s|
Rakefile
color_routes.gemspec
lib/color_routes.rb
+ lib/color_routes/rails/tasks/color_routes.rake
+ lib/color_routes/string_ansi.rb
]
# = MANIFEST =
end
View
@@ -1,3 +1,11 @@
module ColorRoutes
VERSION="0.0.1"
-end
+
+ module Rails
+ class Railtie < ::Rails::Railtie
+ rake_tasks do
+ load "color_routes/rails/tasks/color_routes.rake"
+ end
+ end
+ end
+end
@@ -1,7 +1,7 @@
module ColorRoutes
# Some extensions to String to deal with ANSI colors.
- class StringANSI
+ module StringANSI
COLORS = {
:black => 30,

0 comments on commit ad2617a

Please sign in to comment.