spree 1.1.6 → 1.2.0.rc1
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.
- data/README.md +39 -17
- data/lib/sandbox.sh +10 -0
- data/lib/spree.rb +0 -1
- metadata +33 -50
- data/lib/generators/spree/site/site_generator.rb +0 -18
data/README.md
CHANGED
@@ -1,6 +1,10 @@
|
|
1
|
+
**THIS README IS FOR THE MASTER BRANCH OF SPREE AND REFLECTS THE WORK CURRENTLY EXISTING ON THE MASTER BRANCH. IF YOU ARE WISHING TO USE A NON-MASTER BRANCH OF
|
2
|
+
SPREE, PLEASE CONSULT THAT BRANCH'S README AND NOT THIS ONE.**
|
3
|
+
|
1
4
|
SUMMARY
|
2
5
|
-------
|
3
6
|
|
7
|
+
|
4
8
|
Spree is a complete open source e-commerce solution built with Ruby on Rails. It was originally developed by Sean Schofield
|
5
9
|
and is now maintained by a dedicated [core team](http://spreecommerce.com/core-team). You can find out more
|
6
10
|
by visiting the [Spree e-commerce project page](http://spreecommerce.com).
|
@@ -10,7 +14,6 @@ in a single set of [online documentation](http://spreecommerce.com/documentation
|
|
10
14
|
automatically require all of the necessary gem dependencies which are:
|
11
15
|
|
12
16
|
* spree_api
|
13
|
-
* spree_auth
|
14
17
|
* spree_cmd
|
15
18
|
* spree_core
|
16
19
|
* spree_dash
|
@@ -19,9 +22,9 @@ automatically require all of the necessary gem dependencies which are:
|
|
19
22
|
|
20
23
|
All of the gems are designed to work together to provide a fully functional e-commerce platform. It is also possible,
|
21
24
|
however, to use only the pieces you are interested in. So for example, you could use just the barebones spree\_core gem
|
22
|
-
and perhaps combine it with your own custom
|
25
|
+
and perhaps combine it with your own custom promotion scheme instead of using spree_promo.
|
23
26
|
|
24
|
-
[![Build Status](https://secure.travis-ci.org/spree/spree.png
|
27
|
+
[![Build Status](https://secure.travis-ci.org/spree/spree.png)](http://travis-ci.org/spree/spree)
|
25
28
|
|
26
29
|
Installation
|
27
30
|
------------
|
@@ -29,9 +32,9 @@ Installation
|
|
29
32
|
The fastest way to get started is by using the spree command line tool
|
30
33
|
available in the spree gem which will add Spree to an existing Rails application.
|
31
34
|
|
32
|
-
$ gem install rails -v 3.2.
|
35
|
+
$ gem install rails -v 3.2.7
|
33
36
|
$ gem install spree
|
34
|
-
$ rails _3.2.
|
37
|
+
$ rails _3.2.7_ new my_store
|
35
38
|
$ spree install my_store
|
36
39
|
|
37
40
|
This will add the Spree gem to your Gemfile, create initializers, copy migrations and
|
@@ -52,7 +55,7 @@ You can manually add Spree to your Rails 3.2.x application. Add Spree to
|
|
52
55
|
your Gemfile.
|
53
56
|
|
54
57
|
```ruby
|
55
|
-
gem 'spree', '
|
58
|
+
gem 'spree', :git => 'git://github.com/spree/spree.git'
|
56
59
|
```
|
57
60
|
|
58
61
|
Update your bundle
|
@@ -97,21 +100,21 @@ The source code is essentially a collection of gems. Spree is meant to be run w
|
|
97
100
|
|
98
101
|
1. Clone the Git repo
|
99
102
|
|
100
|
-
|
101
|
-
|
103
|
+
git clone git://github.com/spree/spree.git
|
104
|
+
cd spree
|
102
105
|
|
103
106
|
2. Install the gem dependencies
|
104
107
|
|
105
|
-
|
108
|
+
bundle install
|
106
109
|
|
107
110
|
3. Create a sandbox Rails application for testing purposes (and automatically perform all necessary database setup)
|
108
111
|
|
109
|
-
|
112
|
+
bundle exec rake sandbox
|
110
113
|
|
111
114
|
4. Start the server
|
112
115
|
|
113
|
-
|
114
|
-
|
116
|
+
cd sandbox
|
117
|
+
rails server
|
115
118
|
|
116
119
|
Performance
|
117
120
|
-----------
|
@@ -126,13 +129,23 @@ If you want to remove precompiled assets (recommended before you commit to Git a
|
|
126
129
|
|
127
130
|
$ bundle exec rake assets:clean
|
128
131
|
|
129
|
-
|
130
|
-
|
132
|
+
Use Dedicated Spree Devise Authentication
|
133
|
+
-----------------------------------------
|
134
|
+
Add the following to your Gemfile
|
131
135
|
|
132
|
-
|
136
|
+
$ gem 'spree_auth_devise', :git => 'git://github.com/spree/spree_auth_devise'
|
137
|
+
|
138
|
+
Then run `bundle install`. Authentication will then work exactly as it did in previous versions of Spree.
|
133
139
|
|
134
|
-
|
135
|
-
|
140
|
+
If you're installing this in a new Spree 1.2+ application, you'll need to install and run the migrations with
|
141
|
+
|
142
|
+
$ bundle exec rake spree_auth:install:migrations
|
143
|
+
$ bundle exec rake db:migrate
|
144
|
+
|
145
|
+
and then run `bundle exec rake spree_auth:admin:create` in order to set up the admin user for the application.
|
146
|
+
|
147
|
+
Running Tests
|
148
|
+
-------------
|
136
149
|
|
137
150
|
Each gem contains its own series of tests, and for each directory, you need to do a quick one-time
|
138
151
|
creation of a test application and then you can use it to run the tests. For example, to run the
|
@@ -161,6 +174,15 @@ If you want to run a particular line of spec
|
|
161
174
|
|
162
175
|
$ bundle exec rspec spec/models/state_spec.rb:7
|
163
176
|
|
177
|
+
Travis, the continuous integration service, runs the test suite for each gem one at a time.
|
178
|
+
|
179
|
+
$ alias set_gemfile='export BUNDLE_GEMFILE="`pwd`/Gemfile"'
|
180
|
+
$ bundle exec rake test_app
|
181
|
+
$ cd api; set_gemfile; bundle install; bundle exec rspec spec
|
182
|
+
$ cd ../core; set_gemfile; bundle install; bundle exec rspec spec
|
183
|
+
$ cd ../dash; set_gemfile; bundle install; bundle exec rspec spec
|
184
|
+
$ cd ../promo; set_gemfile; bundle install; bundle exec rspec spec
|
185
|
+
|
164
186
|
|
165
187
|
Contributing
|
166
188
|
------------
|
data/lib/sandbox.sh
ADDED
@@ -0,0 +1,10 @@
|
|
1
|
+
# Used in the sandbox rake task in Rakefile
|
2
|
+
#!/bin/bash
|
3
|
+
rm -rf sandbox
|
4
|
+
rails new sandbox --skip-bundle
|
5
|
+
cd sandbox
|
6
|
+
echo "gem 'spree', :path => '..'" >> Gemfile
|
7
|
+
echo "gem 'spree_auth_devise', :git => 'git://github.com/spree/spree_auth_devise'" >> Gemfile
|
8
|
+
bundle install --gemfile Gemfile
|
9
|
+
rails g spree:install --auto-accept
|
10
|
+
rake assets:precompile
|
data/lib/spree.rb
CHANGED
metadata
CHANGED
@@ -1,128 +1,112 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: spree
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
|
5
|
-
|
4
|
+
version: 1.2.0.rc1
|
5
|
+
prerelease: 6
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
8
8
|
- Sean Schofield
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2012-08-09 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
|
-
type: :runtime
|
16
|
-
version_requirements: !ruby/object:Gem::Requirement
|
17
|
-
none: false
|
18
|
-
requirements:
|
19
|
-
- - '='
|
20
|
-
- !ruby/object:Gem::Version
|
21
|
-
version: 1.1.6
|
22
15
|
name: spree_core
|
23
|
-
prerelease: false
|
24
16
|
requirement: !ruby/object:Gem::Requirement
|
25
17
|
none: false
|
26
18
|
requirements:
|
27
19
|
- - '='
|
28
20
|
- !ruby/object:Gem::Version
|
29
|
-
version: 1.
|
30
|
-
- !ruby/object:Gem::Dependency
|
21
|
+
version: 1.2.0.rc1
|
31
22
|
type: :runtime
|
32
|
-
version_requirements: !ruby/object:Gem::Requirement
|
33
|
-
none: false
|
34
|
-
requirements:
|
35
|
-
- - '='
|
36
|
-
- !ruby/object:Gem::Version
|
37
|
-
version: 1.1.6
|
38
|
-
name: spree_auth
|
39
23
|
prerelease: false
|
40
|
-
requirement: !ruby/object:Gem::Requirement
|
41
|
-
none: false
|
42
|
-
requirements:
|
43
|
-
- - '='
|
44
|
-
- !ruby/object:Gem::Version
|
45
|
-
version: 1.1.6
|
46
|
-
- !ruby/object:Gem::Dependency
|
47
|
-
type: :runtime
|
48
24
|
version_requirements: !ruby/object:Gem::Requirement
|
49
25
|
none: false
|
50
26
|
requirements:
|
51
27
|
- - '='
|
52
28
|
- !ruby/object:Gem::Version
|
53
|
-
version: 1.
|
29
|
+
version: 1.2.0.rc1
|
30
|
+
- !ruby/object:Gem::Dependency
|
54
31
|
name: spree_api
|
55
|
-
prerelease: false
|
56
32
|
requirement: !ruby/object:Gem::Requirement
|
57
33
|
none: false
|
58
34
|
requirements:
|
59
35
|
- - '='
|
60
36
|
- !ruby/object:Gem::Version
|
61
|
-
version: 1.
|
62
|
-
- !ruby/object:Gem::Dependency
|
37
|
+
version: 1.2.0.rc1
|
63
38
|
type: :runtime
|
39
|
+
prerelease: false
|
64
40
|
version_requirements: !ruby/object:Gem::Requirement
|
65
41
|
none: false
|
66
42
|
requirements:
|
67
43
|
- - '='
|
68
44
|
- !ruby/object:Gem::Version
|
69
|
-
version: 1.
|
45
|
+
version: 1.2.0.rc1
|
46
|
+
- !ruby/object:Gem::Dependency
|
70
47
|
name: spree_dash
|
71
|
-
prerelease: false
|
72
48
|
requirement: !ruby/object:Gem::Requirement
|
73
49
|
none: false
|
74
50
|
requirements:
|
75
51
|
- - '='
|
76
52
|
- !ruby/object:Gem::Version
|
77
|
-
version: 1.
|
78
|
-
- !ruby/object:Gem::Dependency
|
53
|
+
version: 1.2.0.rc1
|
79
54
|
type: :runtime
|
55
|
+
prerelease: false
|
80
56
|
version_requirements: !ruby/object:Gem::Requirement
|
81
57
|
none: false
|
82
58
|
requirements:
|
83
59
|
- - '='
|
84
60
|
- !ruby/object:Gem::Version
|
85
|
-
version: 1.
|
61
|
+
version: 1.2.0.rc1
|
62
|
+
- !ruby/object:Gem::Dependency
|
86
63
|
name: spree_sample
|
87
|
-
prerelease: false
|
88
64
|
requirement: !ruby/object:Gem::Requirement
|
89
65
|
none: false
|
90
66
|
requirements:
|
91
67
|
- - '='
|
92
68
|
- !ruby/object:Gem::Version
|
93
|
-
version: 1.
|
94
|
-
- !ruby/object:Gem::Dependency
|
69
|
+
version: 1.2.0.rc1
|
95
70
|
type: :runtime
|
71
|
+
prerelease: false
|
96
72
|
version_requirements: !ruby/object:Gem::Requirement
|
97
73
|
none: false
|
98
74
|
requirements:
|
99
75
|
- - '='
|
100
76
|
- !ruby/object:Gem::Version
|
101
|
-
version: 1.
|
77
|
+
version: 1.2.0.rc1
|
78
|
+
- !ruby/object:Gem::Dependency
|
102
79
|
name: spree_promo
|
103
|
-
prerelease: false
|
104
80
|
requirement: !ruby/object:Gem::Requirement
|
105
81
|
none: false
|
106
82
|
requirements:
|
107
83
|
- - '='
|
108
84
|
- !ruby/object:Gem::Version
|
109
|
-
version: 1.
|
110
|
-
- !ruby/object:Gem::Dependency
|
85
|
+
version: 1.2.0.rc1
|
111
86
|
type: :runtime
|
87
|
+
prerelease: false
|
112
88
|
version_requirements: !ruby/object:Gem::Requirement
|
113
89
|
none: false
|
114
90
|
requirements:
|
115
91
|
- - '='
|
116
92
|
- !ruby/object:Gem::Version
|
117
|
-
version: 1.
|
93
|
+
version: 1.2.0.rc1
|
94
|
+
- !ruby/object:Gem::Dependency
|
118
95
|
name: spree_cmd
|
119
|
-
prerelease: false
|
120
96
|
requirement: !ruby/object:Gem::Requirement
|
121
97
|
none: false
|
122
98
|
requirements:
|
123
99
|
- - '='
|
124
100
|
- !ruby/object:Gem::Version
|
125
|
-
version: 1.
|
101
|
+
version: 1.2.0.rc1
|
102
|
+
type: :runtime
|
103
|
+
prerelease: false
|
104
|
+
version_requirements: !ruby/object:Gem::Requirement
|
105
|
+
none: false
|
106
|
+
requirements:
|
107
|
+
- - '='
|
108
|
+
- !ruby/object:Gem::Version
|
109
|
+
version: 1.2.0.rc1
|
126
110
|
description: ! 'Spree is an open source e-commerce framework for Ruby on Rails. Join
|
127
111
|
us on the spree-user google group or in #spree on IRC'
|
128
112
|
email: sean@spreecommerce.com
|
@@ -131,11 +115,10 @@ extensions: []
|
|
131
115
|
extra_rdoc_files: []
|
132
116
|
files:
|
133
117
|
- README.md
|
134
|
-
- lib/
|
118
|
+
- lib/sandbox.sh
|
135
119
|
- lib/spree.rb
|
136
120
|
homepage: http://spreecommerce.com
|
137
|
-
licenses:
|
138
|
-
- BSD-3
|
121
|
+
licenses: []
|
139
122
|
post_install_message:
|
140
123
|
rdoc_options: []
|
141
124
|
require_paths:
|
@@ -1,18 +0,0 @@
|
|
1
|
-
require 'rails/generators'
|
2
|
-
require 'generators/spree/install/install_generator'
|
3
|
-
|
4
|
-
module Spree
|
5
|
-
class SiteGenerator < Rails::Generators::Base
|
6
|
-
class_option :auto_accept, :type => :boolean, :default => false, :aliases => '-A', :desc => "Answer yes to all prompts"
|
7
|
-
|
8
|
-
def run_install_generator
|
9
|
-
if options[:auto_accept]
|
10
|
-
Spree::InstallGenerator.start ["--auto-accept"]
|
11
|
-
else
|
12
|
-
Spree::InstallGenerator.start
|
13
|
-
end
|
14
|
-
|
15
|
-
puts ActiveSupport::Deprecation.warn "rails g spree:site has been deprecated and will be removed in the future, use rails g spree:install instead."
|
16
|
-
end
|
17
|
-
end
|
18
|
-
end
|