Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Request] Generate policy file when using scaffolding #735

Open
james-em opened this issue May 9, 2022 · 3 comments
Open

[Request] Generate policy file when using scaffolding #735

james-em opened this issue May 9, 2022 · 3 comments

Comments

@james-em
Copy link

james-em commented May 9, 2022

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.

@james-em
Copy link
Author

james-em commented May 9, 2022

Linking this in case it helps the implementation https://gist.github.com/annikoff/331f785aa7a207a7945b1eca6eff526b

@Burgestrand
Copy link
Member

FYI this came up again with #785, so I suggested moving that into here.

@hoverjet
Copy link

Hi, I've added #794

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants