recipes/devise.rb in rails_apps_composer-1.4.4 vs recipes/devise.rb in rails_apps_composer-1.4.5
- old
+ new
@@ -18,10 +18,15 @@
else
recipes.delete('devise')
say_wizard "Devise recipe skipped."
end
+if config['canard']
+ gem 'cancan', '>= 0.2.7'
+ recipes << 'canard'
+end
+
if recipes.include? 'devise'
after_bundler do
say_wizard "Devise recipe running 'after bundler'"
@@ -74,11 +79,11 @@
remove_file 'spec/views/users/show.html.erb_spec.rb'
remove_file 'spec/views/users/show.html.haml_spec.rb'
remove_file 'spec/helpers/home_helper_spec.rb'
remove_file 'spec/helpers/users_helper_spec.rb'
end
-
+
end
end
__END__
@@ -92,5 +97,8 @@
config:
- devise:
type: multiple_choice
prompt: Would you like to use Devise for authentication?
choices: [["No", no], ["Devise with default modules", standard], ["Devise with Confirmable module", confirmable], ["Devise with Confirmable and Invitable modules", invitable]]
+ - canard:
+ type: boolean
+ prompt: Would you like to manage authorization with CanCan, RoleModel, and Canard?