{"id":20779137,"url":"https://github.com/solidusio/solidus_auth_devise","last_synced_at":"2025-05-16T13:05:52.461Z","repository":{"id":32333758,"uuid":"35909145","full_name":"solidusio/solidus_auth_devise","owner":"solidusio","description":"🔑 Devise authentication for your Solidus store.","archived":false,"fork":false,"pushed_at":"2025-01-08T06:30:30.000Z","size":1151,"stargazers_count":55,"open_issues_count":14,"forks_count":122,"subscribers_count":14,"default_branch":"main","last_synced_at":"2025-05-13T09:08:43.800Z","etag":null,"topics":["ecommerce","ecommerce-platform","hacktoberfest","solidus","solidus-extensions"],"latest_commit_sha":null,"homepage":"http://solidus.io","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/solidusio.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null},"funding":{"open_collective":"solidus"}},"created_at":"2015-05-19T21:20:39.000Z","updated_at":"2025-04-10T05:51:13.000Z","dependencies_parsed_at":"2024-02-24T19:53:42.374Z","dependency_job_id":"b9cf3fa1-5678-46e5-b99f-7d4e4aef602b","html_url":"https://github.com/solidusio/solidus_auth_devise","commit_stats":{"total_commits":795,"total_committers":135,"mean_commits":5.888888888888889,"dds":0.6981132075471699,"last_synced_commit":"9f2500706b54e414bf31938bf5ed0509887007e0"},"previous_names":[],"tags_count":28,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/solidusio%2Fsolidus_auth_devise","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/solidusio%2Fsolidus_auth_devise/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/solidusio%2Fsolidus_auth_devise/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/solidusio%2Fsolidus_auth_devise/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/solidusio","download_url":"https://codeload.github.com/solidusio/solidus_auth_devise/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254535827,"owners_count":22087399,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ecommerce","ecommerce-platform","hacktoberfest","solidus","solidus-extensions"],"created_at":"2024-11-17T13:26:13.443Z","updated_at":"2025-05-16T13:05:52.425Z","avatar_url":"https://github.com/solidusio.png","language":"Ruby","readme":"# Solidus Auth Devise\n\n[![CircleCI](https://circleci.com/gh/solidusio/solidus_auth_devise.svg?style=shield)](https://circleci.com/gh/solidusio/solidus_auth_devise)\n[![codecov](https://codecov.io/gh/solidusio/solidus_auth_devise/branch/main/graph/badge.svg)](https://codecov.io/gh/solidusio/solidus_auth_devise)\n\nProvides authentication services for Solidus, using the Devise gem.\n\n## Usage\n\n### Installation\n\nAdd solidus_auth_devise to your Gemfile:\n\n```ruby\ngem 'solidus_auth_devise'\n```\n\nThen, run `bundle install`.\n\nAfter that's done, you can install and run the necessary migrations, then seed the database:\n\n```shell\nbundle exec rake solidus_auth:install:migrations\nbundle exec rake db:migrate\nbundle exec rake db:seed\n```\n\n#### Default Username/Password\n\nAs part of running the above installation steps, you will be asked to set an admin email/password combination. The default values are `admin@example.com` and `test123`, respectively.\n\n#### Confirmable\n\nTo enable Devise's Confirmable module, which will send the user an email with a link to confirm their account, you must do the following:\n\n* Add this line to an initializer in your Rails project (typically `config/initializers/spree.rb`):\n\n```ruby\nSpree::Auth::Config[:confirmable] = true\n```\n\n* Add a Devise initializer to your Rails project (typically `config/initializers/devise.rb`):\n\n```ruby\nDevise.setup do |config|\n  # Required so users don't lose their carts when they need to confirm.\n  config.allow_unconfirmed_access_for = 1.days\n\n  # Add any other devise configurations here, as they will override the defaults provided by solidus_auth_devise.\nend\n```\n\n### Using in an existing application\n\nIf you are installing Solidus inside of a host application in which you want your own permission setup, you can do this using the `register_ability` method.\n\nFirst create your own CanCan Ability class following the CanCan documentation.\n\nFor example: `app/models/super_abilities.rb`\n\n```ruby\nclass SuperAbilities\n  include CanCan::Ability\n\n  def initialize user\n    if user.is? \"Superman\"\n      can :stop, Bullet\n    end\n  end\nend\n```\n\nThen register your class in your spree initializer: config/initializers/spree.rb\n\n```ruby\nSpree::Ability.register_ability(SuperAbilities)\n```\n\nInside of your host application you can then use CanCan like you normally would.\n\n```erb\n\u003c% if can? :stop Bullet %\u003e\n  ...\n\u003c% end %\u003e\n```\n\n## Development\n\n### Testing the extension\n\nFirst bundle your dependencies, then run `bin/rake`. `bin/rake` will default to building the dummy\napp if it does not exist, then it will run specs. The dummy app can be regenerated by using\n`bin/rake extension:test_app`.\n\n```shell\nbin/rake\n```\n\nTo run [Rubocop](https://github.com/bbatsov/rubocop) static code analysis run\n\n```shell\nbundle exec rubocop\n```\n\nWhen testing your application's integration with this extension you may use its factories.\nSimply add this require statement to your `spec/spec_helper.rb`:\n\n```ruby\nrequire 'solidus_auth_devise/testing_support/factories'\n```\n\nOr, if you are using `FactoryBot.definition_file_paths`, you can load Solidus core\nfactories along with this extension's factories using this statement:\n\n```ruby\nSolidusDevSupport::TestingSupport::Factories.load_for(SolidusAuthDevise::Engine)\n```\n\n### Running the sandbox\n\nTo run this extension in a sandboxed Solidus application, you can run `bin/sandbox`. The path for\nthe sandbox app is `./sandbox` and `bin/rails` will forward any Rails commands to\n`sandbox/bin/rails`.\n\nHere's an example:\n\n```\n$ bin/rails server\n=\u003e Booting Puma\n=\u003e Rails 6.0.2.1 application starting in development\n* Listening on tcp://127.0.0.1:3000\nUse Ctrl-C to stop\n```\n\n### Updating the changelog\n\nBefore and after releases the changelog should be updated to reflect the up-to-date status of\nthe project:\n\n```shell\nbin/rake changelog\ngit add CHANGELOG.md\ngit commit -m \"Update the changelog\"\n```\n\n### Releasing new versions\n\nPlease refer to the dedicated [page](https://github.com/solidusio/solidus/wiki/How-to-release-extensions) on Solidus wiki.\n\n## License\n\nCopyright (c) 2022 Solidus Team, released under the New BSD License.\n","funding_links":["https://opencollective.com/solidus"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsolidusio%2Fsolidus_auth_devise","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsolidusio%2Fsolidus_auth_devise","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsolidusio%2Fsolidus_auth_devise/lists"}