Permalink
Browse files

remove the unused generator tasks from the Rakefile

  • Loading branch information...
1 parent 6808e27 commit 4b161f1dd34b9d0048e4a25280db1c0e3cdfb318 @mike-burns mike-burns committed Oct 24, 2008
Showing with 0 additions and 25 deletions.
  1. +0 −25 Rakefile
View
@@ -31,29 +31,4 @@ namespace :generator do
system "cp -R generators test/rails_root/vendor/plugins/clearance"
system "cd test/rails_root; ./script/generate clearance"
end
-
- task :templates do
- app_files = FileList["test/rails_root/app/{controllers,models,views}/**/*"]
- app_files.reject! { |file| file.include?("test/rails_root/app/views/layouts") }
- test_files = FileList["test/rails_root/test/{functional,unit}/**/*"]
- test_files += ["test/rails_root/test/factories.rb"]
- files = test_files + app_files
- templates_path = "generators/clearance/templates"
- system `rm -rf #{templates_path}`
- system `mkdir #{templates_path}`
- ["app", "app/controllers", "app/models", "app/views",
- "test", "test/functional", "test/unit"].each do |directory|
- system `mkdir #{templates_path}/#{directory}`
- end
- files.each do |file|
- template = "generators/clearance/templates/#{file.gsub("test/rails_root/", "")}"
- if File.directory?(file)
- system `rm -rf #{template}`
- system `mkdir #{template}`
- else
- system `rm #{template}` if File.exists?(template)
- system `cp #{file} #{template}`
- end
- end
- end
end

0 comments on commit 4b161f1

Please sign in to comment.