pundit
pundit copied to clipboard
[Request] Generate policy file when using scaffolding
Hi,
It would be great if running
rails g scaffold Model
rails g controller Model
would actually generate an empty policy file that inherits from ApplicationPolicy.
As a bonus, for resources scaffolding, maybe we could implements all CRUD actions and defaults to false.
Linking this in case it helps the implementation https://gist.github.com/annikoff/331f785aa7a207a7945b1eca6eff526b
FYI this came up again with #785, so I suggested moving that into here.
Hi, I've added https://github.com/varvet/pundit/pull/794