solidusio-contrib / solidus_cmd Goto Github PK
View Code? Open in Web Editor NEW⌨️ Command-line utility for creating Solidus extensions.
License: BSD 3-Clause "New" or "Revised" License
⌨️ Command-line utility for creating Solidus extensions.
License: BSD 3-Clause "New" or "Revised" License
The provided spec_helper could be improved, I think we need to use testing helpers provided by solidus_support.
We started using https://github.com/solidusio-contrib/solidus_extension_dev_tools/ in existing extensions to group and share boilerplates code between these gems.
We should reflect this convention here.
How to reproduce:
solidus extension ExtensionName
cd ExtensionName
bundle update
bundle exec rake test_app
The above line have no issue with Solidus at commit bed8abd2c78ec6480cee7804760abd7d0d86b46a
; but it has error at commit e76d0189a9e0d620c3f5228c64b5dcc6b4b5abe0
.
Error Content:
➜ solidus_elastic_search git:(master) be rake test_app
<<<
[DEPRECATION] `last_comment` is deprecated. Please use `last_description`
instead.
Generating dummy Rails application...
Setting up dummy database...
bundle exec rake db:drop db:create db:migrate
rake aborted!
ActiveSupport::DeprecationException: DEPRECATION WARNING:
Spree::Core::Engine.add_routes is deprecated, use
Spree::Core::Engine.routes.draw instead. (called from <top (required)> at
/Users/songyy/.rvm/gems/ruby-2.3.1/bundler/gems/solidus_flexible_variants-8f2e76890fc5/config/routes.rb:1)
/Users/songyy/.rvm/gems/ruby-2.3.1/bundler/gems/solidus_flexible_variants-8f2e76890fc5/config/routes.rb:1:in
`<top (required)>'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:268:in
`load'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:268:in
`block in load'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:240:in
`load_dependency'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:268:in
`load'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/railties-4.2.6/lib/rails/application/routes_reloader.rb:40:in
`block in load_paths'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/railties-4.2.6/lib/rails/application/routes_reloader.rb:40:in
`each'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/railties-4.2.6/lib/rails/application/routes_reloader.rb:40:in
`load_paths'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/railties-4.2.6/lib/rails/application/routes_reloader.rb:16:in
`reload!'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/railties-4.2.6/lib/rails/application/routes_reloader.rb:26:in
`block in updater'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/activesupport-4.2.6/lib/active_support/file_update_checker.rb:75:in
`execute'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/railties-4.2.6/lib/rails/application/routes_reloader.rb:27:in
`updater'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/railties-4.2.6/lib/rails/application/routes_reloader.rb:7:in
`execute_if_updated'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/railties-4.2.6/lib/rails/application/finisher.rb:69:in
`block in <module:Finisher>'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/railties-4.2.6/lib/rails/initializable.rb:30:in
`instance_exec'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/railties-4.2.6/lib/rails/initializable.rb:30:in
`run'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/railties-4.2.6/lib/rails/initializable.rb:55:in
`block in run_initializers'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/railties-4.2.6/lib/rails/initializable.rb:54:in
`run_initializers'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/railties-4.2.6/lib/rails/application.rb:352:in
`initialize!'
/Users/songyy/work/Knight/engine/solidus_elastic_search/spec/dummy/config/environment.rb:5:in
`<top (required)>'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/polyglot-0.3.5/lib/polyglot.rb:65:in
`require'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/polyglot-0.3.5/lib/polyglot.rb:65:in
`require'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:274:in
`block in require'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:240:in
`load_dependency'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:274:in
`require'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/railties-4.2.6/lib/rails/application.rb:328:in
`require_environment!'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/railties-4.2.6/lib/rails/application.rb:457:in
`block in run_tasks_blocks'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/rake-11.2.2/exe/rake:27:in `<top
(required)>'
/Users/songyy/.rvm/gems/ruby-2.3.1/bin/ruby_executable_hooks:15:in `eval'
/Users/songyy/.rvm/gems/ruby-2.3.1/bin/ruby_executable_hooks:15:in `<main>'
Tasks: TOP => db:migrate => environment
(See full trace by running task with --trace)
rake aborted!
Command failed with status (1): [bundle exec rake db:drop db:create db:migr...]
/Users/songyy/.rvm/gems/ruby-2.3.1/bundler/gems/solidus-e76d0189a9e0/core/lib/spree/testing_support/common_rake.rb:21:in
`block (3 levels) in <top (required)>'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/activesupport-4.2.6/lib/active_support/core_ext/kernel/reporting.rb:55:in
`silence_stream'
/Users/songyy/.rvm/gems/ruby-2.3.1/bundler/gems/solidus-e76d0189a9e0/core/lib/spree/testing_support/common_rake.rb:20:in
`block (2 levels) in <top (required)>'
/Users/songyy/.rvm/gems/ruby-2.3.1/bundler/gems/solidus-e76d0189a9e0/core/lib/spree/testing_support/extension_rake.rb:7:in
`block (2 levels) in <top (required)>'
/Users/songyy/work/Knight/engine/solidus_elastic_search/Rakefile:29:in `block in
<top (required)>'
/Users/songyy/.rvm/gems/ruby-2.3.1/gems/rake-11.2.2/exe/rake:27:in `<top
(required)>'
/Users/songyy/.rvm/gems/ruby-2.3.1/bin/ruby_executable_hooks:15:in `eval'
/Users/songyy/.rvm/gems/ruby-2.3.1/bin/ruby_executable_hooks:15:in `<main>'
Tasks: TOP => common:test_app
(See full trace by running task with --trace)
After setting up the dummy app the following warnings appear when the app loads:
[WARNING] You are not setting Devise.secret_key within your application!
You must set this in config/initializers/devise.rb. Here's an example:
Devise.secret_key = "454360bb1e74cc798944b7defda59b291a40b376e71b48c2b1615134859400af0ebdbd841460e8f5992d152fb55444d29f79"
It would be nice to not have to set this manually everytime a dummy app gets setup for Solidus gems.
One this PR is merged on solidus_support, we should reflect the change over here to use this convention for new extensions.
The most recent (stable) version of Solidus should be a dependency
Setting the default to 1.0 causes an issue because the Gemfile is set to get the most recent version of Solidus from GitHub.
Attempting to add this extension to a Solidus instance results in this:
Happy to hear opinions on this, but I'm in favor of removing the version from the dependency and leaving an instructive comment that recommends setting the version number.
It'd be nice if our ecosystem followed a consistent style guide. I believe that was the impetus behind including Rubocop in the default build task. However, it's natural that .rubocop.yml
will fall out of sync with https://github.com/solidusio/solidus/blob/master/.rubocop.yml overtime. In order to keep the ecosystem consistent, we could add a rake task which diffs the current master version of .rubycop.yml
against your local copy.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.