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

Shouldn't rails generate oauth_provider also generate views? #50

Closed
asavin opened this issue Mar 1, 2011 · 3 comments
Closed

Shouldn't rails generate oauth_provider also generate views? #50

asavin opened this issue Mar 1, 2011 · 3 comments

Comments

@asavin
Copy link

asavin commented Mar 1, 2011

Trying to use oauth-plugin with Rails 3 application. When running rails generate oauth_provider I get models and controllers generated successfully. But no views. Those are missing completely, though I think they should be generated as well. At least according to this tutorial: http://stakeventures.com/articles/2007/11/26/how-to-turn-your-rails-site-into-an-oauth-provider

Gemfile:

gem 'rails'
gem 'simple_form'
gem 'paperclip', '~> 2.3'
gem 'devise', '1.2.rc'
gem 'oa-oauth', :require => 'omniauth/oauth'
gem 'jquery-rails', '>= 0.2.6'
gem 'oauth'
gem 'oauth-plugin', '>=0.4.0.pre1'

These are generated:
invoke active_record
identical app/models/client_application.rb
identical app/models/oauth_token.rb
identical app/models/request_token.rb
identical app/models/access_token.rb
identical app/models/oauth2_token.rb
identical app/models/oauth2_verifier.rb
identical app/models/oauth_nonce.rb

Wonder is it an issue?

@afeld
Copy link
Contributor

afeld commented May 25, 2011

I believe the views aren't generated because they aren't needed - most of the oauth actions are just redirects. If you need views you can add them.

@Gurpartap
Copy link

$ rails generate oauth_provider oauth # will generate everything, including injecting routes.

@pelle
Copy link
Owner

pelle commented Jun 28, 2011

This was a bug in the erb generator. It is fixed now.

@pelle pelle closed this as completed Jun 28, 2011
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants