spree 0.60.6 → 0.70.7

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of spree might be problematic. Click here for more details.

Files changed (41) hide show
  1. data/README.md +41 -32
  2. data/lib/spree/bin/spree +6 -0
  3. data/lib/spree/cli.rb +52 -0
  4. data/lib/spree/engine.rb +5 -0
  5. data/lib/spree/extension.rb +77 -0
  6. data/lib/spree/templates/extension/Gemfile +22 -0
  7. data/lib/{generators/templates → spree/templates/extension}/LICENSE +11 -8
  8. data/lib/{generators/templates → spree/templates/extension}/README.md +7 -0
  9. data/lib/spree/templates/extension/Rakefile +36 -0
  10. data/lib/{generators/templates/Versionfile.tt → spree/templates/extension/Versionfile} +2 -2
  11. data/lib/spree/templates/extension/app/assets/javascripts/admin/%file_name%.js +1 -0
  12. data/lib/spree/templates/extension/app/assets/javascripts/store/%file_name%.js +1 -0
  13. data/lib/spree/templates/extension/app/assets/stylesheets/admin/%file_name%.css +3 -0
  14. data/lib/spree/templates/extension/app/assets/stylesheets/store/%file_name%.css +3 -0
  15. data/lib/{generators/templates/extension.gemspec.tt → spree/templates/extension/extension.gemspec} +7 -3
  16. data/lib/{generators/templates/gitignore.tt → spree/templates/extension/gitignore} +1 -0
  17. data/lib/spree/templates/extension/lib/%file_name%/engine.rb.tt +24 -0
  18. data/lib/spree/templates/extension/lib/%file_name%.rb.tt +2 -0
  19. data/lib/spree/templates/extension/lib/generators/%file_name%/install/install_generator.rb.tt +29 -0
  20. data/lib/{generators/templates → spree/templates/extension}/routes.rb +0 -0
  21. data/lib/spree/templates/extension/rspec +1 -0
  22. data/lib/spree/templates/extension/script/rails.tt +12 -0
  23. data/lib/spree/templates/extension/spec_helper.rb.tt +33 -0
  24. data/lib/spree.rb +1 -4
  25. metadata +78 -78
  26. data/lib/generators/spree/extension_generator.rb +0 -71
  27. data/lib/generators/spree/site_generator.rb +0 -45
  28. data/lib/generators/spree/test_app_generator.rb +0 -145
  29. data/lib/generators/templates/Gemfile +0 -32
  30. data/lib/generators/templates/Rakefile.tt +0 -75
  31. data/lib/generators/templates/config/database.yml +0 -17
  32. data/lib/generators/templates/config/database.yml.mysql +0 -29
  33. data/lib/generators/templates/config/database.yml.sqlite3 +0 -17
  34. data/lib/generators/templates/config/environments/cucumber.rb +0 -38
  35. data/lib/generators/templates/extension/extension.rb.tt +0 -17
  36. data/lib/generators/templates/hooks.rb.tt +0 -3
  37. data/lib/generators/templates/install.rake.tt +0 -25
  38. data/lib/generators/templates/lib/tasks/%file_name%.rake.tt +0 -1
  39. data/lib/generators/templates/spec_helper.rb +0 -30
  40. data/lib/generators/templates/spree_site.rb +0 -12
  41. data/lib/tasks/install.rake +0 -29
@@ -1,38 +0,0 @@
1
- TestApp::Application.configure do
2
- # Settings specified here will take precedence over those in config/environment.rb
3
-
4
- # The test environment is used exclusively to run your application's
5
- # test suite. You never need to work with it otherwise. Remember that
6
- # your test database is "scratch space" for the test suite and is wiped
7
- # and recreated between test runs. Don't rely on the data there!
8
- config.cache_classes = true
9
-
10
- # Log error messages when you accidentally call methods on nil.
11
- config.whiny_nils = true
12
-
13
- # Show full error reports and disable caching
14
- config.consider_all_requests_local = true
15
- config.action_controller.perform_caching = false
16
-
17
- # Raise exceptions instead of rendering exception templates
18
- config.action_dispatch.show_exceptions = false
19
-
20
- # Disable request forgery protection in test environment
21
- config.action_controller.allow_forgery_protection = false
22
-
23
- # Tell Action Mailer not to deliver emails to the real world.
24
- # The :test delivery method accumulates sent emails in the
25
- # ActionMailer::Base.deliveries array.
26
- config.action_mailer.delivery_method = :test
27
-
28
- # Use SQL instead of Active Record's schema dumper when creating the test database.
29
- # This is necessary if your schema can't be completely dumped by the schema dumper,
30
- # like if you have constraints or database-specific column types
31
- # config.active_record.schema_format = :sql
32
-
33
- # Print deprecation notices to the stderr
34
- config.active_support.deprecation = :stderr
35
-
36
- config.action_mailer.default_url_options = { :host => 'testapp.com' }
37
-
38
- end
@@ -1,17 +0,0 @@
1
- require 'spree_core'
2
- require '<%=file_name%>_hooks'
3
-
4
- module <%=class_name%>
5
- class Engine < Rails::Engine
6
-
7
- config.autoload_paths += %W(#{config.root}/lib)
8
-
9
- def self.activate
10
- Dir.glob(File.join(File.dirname(__FILE__), "../app/**/*_decorator*.rb")) do |c|
11
- Rails.env.production? ? require(c) : load(c)
12
- end
13
- end
14
-
15
- config.to_prepare &method(:activate).to_proc
16
- end
17
- end
@@ -1,3 +0,0 @@
1
- class <%=class_name%>Hooks < Spree::ThemeSupport::HookListener
2
- # custom hooks go here
3
- end
@@ -1,25 +0,0 @@
1
- namespace :<%= file_name %> do
2
- desc "Copies all migrations and assets (NOTE: This will be obsolete with Rails 3.1)"
3
- task :install do
4
- Rake::Task['<%= file_name %>:install:migrations'].invoke
5
- Rake::Task['<%= file_name %>:install:assets'].invoke
6
- end
7
-
8
- namespace :install do
9
- desc "Copies all migrations (NOTE: This will be obsolete with Rails 3.1)"
10
- task :migrations do
11
- source = File.join(File.dirname(__FILE__), '..', '..', 'db')
12
- destination = File.join(Rails.root, 'db')
13
- Spree::FileUtilz.mirror_files(source, destination)
14
- end
15
-
16
- desc "Copies all assets (NOTE: This will be obsolete with Rails 3.1)"
17
- task :assets do
18
- source = File.join(File.dirname(__FILE__), '..', '..', 'public')
19
- destination = File.join(Rails.root, 'public')
20
- puts "INFO: Mirroring assets from #{source} to #{destination}"
21
- Spree::FileUtilz.mirror_files(source, destination)
22
- end
23
- end
24
-
25
- end
@@ -1 +0,0 @@
1
- # add custom rake tasks here
@@ -1,30 +0,0 @@
1
- # This file is copied to ~/spec when you run 'ruby script/generate rspec'
2
- # from the project root directory.
3
- ENV["RAILS_ENV"] ||= 'test'
4
- require File.expand_path("../test_app/config/environment", __FILE__)
5
- require 'rspec/rails'
6
-
7
- # Requires supporting files with custom matchers and macros, etc,
8
- # in ./support/ and its subdirectories.
9
- Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each {|f| require f}
10
-
11
- RSpec.configure do |config|
12
- # == Mock Framework
13
- #
14
- # If you prefer to use mocha, flexmock or RR, uncomment the appropriate line:
15
- #
16
- # config.mock_with :mocha
17
- # config.mock_with :flexmock
18
- # config.mock_with :rr
19
- config.mock_with :rspec
20
-
21
- config.fixture_path = "#{::Rails.root}/spec/fixtures"
22
-
23
- #config.include Devise::TestHelpers, :type => :controller
24
- # If you're not using ActiveRecord, or you'd prefer not to run each of your
25
- # examples within a transaction, comment the following line or assign false
26
- # instead of true.
27
- config.use_transactional_fixtures = true
28
- end
29
-
30
- @configuration ||= AppConfiguration.find_or_create_by_name("Default configuration")
@@ -1,12 +0,0 @@
1
- module SpreeSite
2
- class Engine < Rails::Engine
3
- def self.activate
4
- # Add your custom site logic here
5
- end
6
-
7
- def load_tasks
8
- end
9
-
10
- config.to_prepare &method(:activate).to_proc
11
- end
12
- end
@@ -1,29 +0,0 @@
1
- namespace :spree do
2
- desc "Copies all migrations and assets (NOTE: This will be obsolete with Rails 3.1)"
3
- task :install do
4
- Rake::Task['spree:install:migrations'].invoke
5
- Rake::Task['spree:install:assets'].invoke
6
- end
7
-
8
- namespace :install do
9
-
10
- desc "Copies all migrations (NOTE: This will be obsolete with Rails 3.1)"
11
- task :migrations do
12
- Rake::Task['spree_core:install:migrations'].invoke
13
- Rake::Task['spree_auth:install:migrations'].invoke
14
- Rake::Task['spree_api:install:migrations'].invoke
15
- Rake::Task['spree_dash:install:migrations'].invoke
16
- Rake::Task['spree_promo:install:migrations'].invoke
17
- end
18
-
19
- desc "Copies all assets (NOTE: This will be obsolete with Rails 3.1)"
20
- task :assets do
21
- Rake::Task['spree_core:install:assets'].invoke
22
- Rake::Task['spree_auth:install:assets'].invoke
23
- Rake::Task['spree_api:install:assets'].invoke
24
- Rake::Task['spree_dash:install:assets'].invoke
25
- Rake::Task['spree_promo:install:assets'].invoke
26
- end
27
-
28
- end
29
- end