GithubHelp home page GithubHelp logo

oath-generators's Introduction

Oath::Generators

Rails generators for adding in authentication components, using the Oath authentication library.

Installation

Add this line to your application's Gemfile:

gem 'oath-generators'

And then execute:

$ bundle

Generators

Currently these are the generators available:

Scaffold

You can generate a basic starting point for any oath app by running the following:

rails g oath:scaffold

Password Reset

If you'd like to generate basic password reset for your app, you can run:

rails g oath:password_reset

This will generate the necessary files for an implementation of resetting a user's password. It will ask you for host names for development, test and production environments in order to make the mailer work.

Google Oauth 2

If you'd like setup basic google oauth authentication, you can run:

rails g oath:google_oauth2

This will generate the necessary files for an implementation of allowing users to sign in either with an email/password or by using google oauth2.

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

oath-generators's People

Contributors

adamantnz avatar gabebw avatar halogenandtoast avatar jsteiner avatar mcquackers avatar reshleman avatar tomichj avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

oath-generators's Issues

Deliver being deprecated

Hey there - I noticed when working with the password_reset generator that password_reset_controller.rb is using #deliver which is being deprecated in rails 5. I think that by default this should be changed to using #deliver_now as per the below warning.

Just wanted to flag this in case this wasn't already on your radar.

DEPRECATION WARNING: #deliver is deprecated and will be removed in Rails 5. Use #deliver_now to deliver immediately or #deliver_later to deliver through Active Job. (called from create at app/controllers/password_resets_controller.rb:12)

monban generator

When running 'rails g monban:scaffold' there seems to be an error. When running 'rake db:migrate RAILS_ENV=development' afterwards there is an error for 'uninitialized constant CreateUsers'

Presence validations and NOT NULL

I believe Monban should:

  • Set email and password_digest columns to NOT NULL (and the timestamps too, for good measure)
  • Generate presence validations for those columns in the User model

Maybe validate that the email is email-y, but I'm not 100% sold on that and it feels like another issue.

I can start work on that, I'm mostly filing this issue to remind myself to work on this.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.