We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 11e2bff + ae73423 commit 54381b8Copy full SHA for 54381b8
lib/haml-rails.rb
@@ -54,6 +54,10 @@ class Railtie < ::Rails::Railtie
54
end
55
56
57
+
58
+ rake_tasks do
59
+ load 'tasks/erb2haml.rake'
60
+ end
61
62
63
lib/tasks/erb2haml.rake
@@ -1,8 +1,7 @@
1
namespace :haml do
2
+ desc 'Convert html.erb to html.haml each file in app/views'
3
task :erb2haml do
4
- puts "This task will generate a .html.haml translation of each of the .html.erb files in app/views and its subdirectories."
5
-
6
erb_files = Dir.glob('app/views/**/*.erb').select { |f| File.file? f}
7
haml_files = Dir.glob('app/views/**/*.haml').select { |f| File.file? f}
8
0 commit comments