Merge pull request #779 from deivid-rodriguez/warnings
Fix warnings with recent versions of `thor`
This commit is contained in:
commit
0bb5cded88
11
README.md
11
README.md
|
@ -107,13 +107,20 @@ Decorators are the ideal place to:
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
Add Draper to your Gemfile:
|
Add Draper to your Gemfile. If you're using `Rails 5`, use the `3.0.0` version
|
||||||
|
pre-release
|
||||||
|
|
||||||
|
```ruby
|
||||||
|
gem 'draper', '3.0.0.pre1'
|
||||||
|
```
|
||||||
|
|
||||||
|
Otherwise, use the latest released version
|
||||||
|
|
||||||
```ruby
|
```ruby
|
||||||
gem 'draper'
|
gem 'draper'
|
||||||
```
|
```
|
||||||
|
|
||||||
And run `bundle install` within your app's directory.
|
After that, run `bundle install` within your app's directory.
|
||||||
|
|
||||||
If you're upgrading from a 0.x release, the major changes are outlined [in the
|
If you're upgrading from a 0.x release, the major changes are outlined [in the
|
||||||
wiki](https://github.com/drapergem/draper/wiki/Upgrading-to-1.0).
|
wiki](https://github.com/drapergem/draper/wiki/Upgrading-to-1.0).
|
||||||
|
|
|
@ -5,13 +5,13 @@ require "rails/generators/rails/scaffold_controller/scaffold_controller_generato
|
||||||
module Rails
|
module Rails
|
||||||
module Generators
|
module Generators
|
||||||
class ControllerGenerator
|
class ControllerGenerator
|
||||||
hook_for :decorator, default: true do |generator|
|
hook_for :decorator, type: :boolean, default: true do |generator|
|
||||||
invoke generator, [name.singularize]
|
invoke generator, [name.singularize]
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
class ScaffoldControllerGenerator
|
class ScaffoldControllerGenerator
|
||||||
hook_for :decorator, default: true
|
hook_for :decorator, type: :boolean, default: true
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue