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

Automatically underscore and pluralize scoped views generator #3792

Merged
merged 1 commit into from Oct 21, 2015

Conversation

Projects
None yet
6 participants
@excid3
Contributor

excid3 commented Oct 21, 2015

This fixes issue #3790.

Example of previous functionality. This basically just doesn't match up with what Devise expects when rendering the views:

rails g devise AdminUser
rails g devise:views AdminUser # incorrectly generates the folder name
=>      create    app/views/AdminUser/shared

When rendering the scoped views, Devise will always look for the underscored and pluralized folder name, so this trips up a few people.

Fixed version:

rails g devise AdminUser
rails g devise:views AdminUser # correctly underscores and pluralizes the scope
=>      create    app/views/admin_users/shared
@nynhex

This comment has been minimized.

Show comment
Hide comment
@nynhex

nynhex commented on 005d514 Oct 21, 2015

+1

josevalim added a commit that referenced this pull request Oct 21, 2015

Merge pull request #3792 from excid3/master
Automatically underscore and pluralize scoped views generator

@josevalim josevalim merged commit d6dc93c into plataformatec:master Oct 21, 2015

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
@rodrigoargumedo

This comment has been minimized.

Show comment
Hide comment
@rodrigoargumedo

rodrigoargumedo Oct 22, 2015

Contributor

+1

Contributor

rodrigoargumedo commented Oct 22, 2015

+1

2 similar comments
@ryanckulp

This comment has been minimized.

Show comment
Hide comment
@ryanckulp

ryanckulp commented Oct 28, 2015

+1

@Davidzhu001

This comment has been minimized.

Show comment
Hide comment
@Davidzhu001

Davidzhu001 commented Nov 12, 2015

+1

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