solidus_frontend 3.3.0.alpha → 3.3.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6d692c8cf2e9d644d15bf0ff289e7c3a66fa43f852a6326d75018a2a4002e637
4
- data.tar.gz: 9961933922ae35466d194483514adafb8c89b4181d22c5175616b3a50e13afb0
3
+ metadata.gz: 47e06ab674abc80fad6b3e70bae98c3e6bc40484a11875492bfb8aea897770e0
4
+ data.tar.gz: b51d9084b6812a51af3fe08bb4c408d135a5d52af52517528cdbf749c548cca2
5
5
  SHA512:
6
- metadata.gz: 7c4bf55673759c0c081d546d9f1ef416f05035548e49e6f1f36e3f54956cc18914af1fd71ef0d323844dad2f3ccd2fe0095e5d7016431d9fabffbb743395d617
7
- data.tar.gz: 9b16f639cc7c8b6e3e2f70f73ee444c6cb20916b542761f3068faf0ac965c6084f57c3f706522abfa13b87e55b5d339594d95297d03956058808afffaac13e1e
6
+ metadata.gz: d3c8ca41ce443bd5d77bab54f229badded11da401ad1261e280e07abb800abee5d8e73a9d287ce171b0428fdbabf0b08b54f996ddf365e3708f28d84975b77a3
7
+ data.tar.gz: 38852e9366c86475fbe0ef683e79187c8e4faf06453db6bce427739d0dfc1d9988c037eed0b49dc85c3025f3032b97d192eb1dff2b362d1c16096084ff63286f
data/.circleci/config.yml CHANGED
@@ -2,6 +2,7 @@ version: 2.1
2
2
 
3
3
  orbs:
4
4
  browser-tools: circleci/browser-tools@1.3
5
+ slack: circleci/slack@4.9.3
5
6
 
6
7
  # Always take the latest version of the orb, this allows us to
7
8
  # run specs against Solidus supported versions only without the need
@@ -14,7 +15,16 @@ commands:
14
15
  steps:
15
16
  - run:
16
17
  name: Install libvips
17
- command: sudo apt-get install -y libvips
18
+ command: |
19
+ sudo apt-get update
20
+ sudo apt-get install -yq libvips-dev
21
+
22
+ notify:
23
+ steps:
24
+ - slack/notify:
25
+ event: fail
26
+ template: basic_fail_1
27
+ branch_pattern: master, v[0-9]+\.[0-9]+
18
28
 
19
29
  jobs:
20
30
  run-specs-with-postgres:
@@ -26,6 +36,7 @@ jobs:
26
36
  - libvips
27
37
  - solidusio_extensions/run-tests-solidus-master
28
38
  - solidusio_extensions/store-test-results
39
+ - notify
29
40
  run-specs-with-mysql:
30
41
  executor: solidusio_extensions/mysql
31
42
  steps:
@@ -35,16 +46,20 @@ jobs:
35
46
  - libvips
36
47
  - solidusio_extensions/run-tests-solidus-master
37
48
  - solidusio_extensions/store-test-results
49
+ - notify
38
50
  lint-code:
39
51
  executor: solidusio_extensions/sqlite-memory
40
52
  steps:
41
53
  - solidusio_extensions/lint-code
54
+ - notify
42
55
 
43
56
  workflows:
44
57
  "Run specs on supported Solidus versions":
45
58
  jobs:
46
- - run-specs-with-postgres
47
- - run-specs-with-mysql
59
+ - run-specs-with-postgres:
60
+ context: slack-secrets
61
+ - run-specs-with-mysql:
62
+ context: slack-secrets
48
63
 
49
64
  "Weekly run specs against master":
50
65
  triggers:
@@ -55,5 +70,7 @@ workflows:
55
70
  only:
56
71
  - master
57
72
  jobs:
58
- - run-specs-with-postgres
59
- - run-specs-with-mysql
73
+ - run-specs-with-postgres:
74
+ context: slack-secrets
75
+ - run-specs-with-mysql:
76
+ context: slack-secrets
data/.github/stale.yml CHANGED
@@ -1,17 +1 @@
1
- # Number of days of inactivity before an issue becomes stale
2
- daysUntilStale: 60
3
- # Number of days of inactivity before a stale issue is closed
4
- daysUntilClose: false
5
- # Issues with these labels will never be considered stale
6
- exemptLabels:
7
- - pinned
8
- - security
9
- # Label to use when marking an issue as stale
10
- staleLabel: stale
11
- # Comment to post when marking an issue as stale. Set to `false` to disable
12
- markComment: >
13
- This issue has been automatically marked as stale because it has not had
14
- recent activity. It might be closed if no further activity occurs. Thank you
15
- for your contributions.
16
- # Comment to post when closing a stale issue. Set to `false` to disable
17
- closeComment: false
1
+ _extends: .github
data/CHANGELOG.md CHANGED
@@ -1,6 +1,33 @@
1
1
  # Changelog
2
2
 
3
- ## Solidus 3.2.0 (v3.2, 2022-08-18)
3
+ ## Solidus v3.3.0 (v3.3, 2023-01-24)
4
+
5
+ - Fix CircleCI errors due to libvips not being found [#27](https://github.com/solidusio/solidus_frontend/pull/27) ([waiting-for-dev](https://github.com/waiting-for-dev))
6
+ - Update Changelog with latest released versions [#26](https://github.com/solidusio/solidus_frontend/pull/26) ([waiting-for-dev](https://github.com/waiting-for-dev))
7
+ - [v3.2] Notify CI failures on Slack [#25](https://github.com/solidusio/solidus_frontend/pull/25) ([waiting-for-dev](https://github.com/waiting-for-dev))
8
+ - Notify CI failures on Slack [#24](https://github.com/solidusio/solidus_frontend/pull/24) ([waiting-for-dev](https://github.com/waiting-for-dev))
9
+ - Touch the robots file before appending to it [#18](https://github.com/solidusio/solidus_frontend/pull/18) ([elia](https://github.com/elia))
10
+ - Handle robots in here [#17](https://github.com/solidusio/solidus_frontend/pull/17) ([elia](https://github.com/elia))
11
+ - [v3.2] Skip trying to install solidus_bolt when there's no Gemfile [#16](https://github.com/solidusio/solidus_frontend/pull/16) ([waiting-for-dev](https://github.com/waiting-for-dev))
12
+ - Skip trying to install solidus_bolt when there's no Gemfile [#15](https://github.com/solidusio/solidus_frontend/pull/15) ([waiting-for-dev](https://github.com/waiting-for-dev))
13
+ - Ask whether to add solidus_bolt during installation [#14](https://github.com/solidusio/solidus_frontend/pull/14) ([waiting-for-dev](https://github.com/waiting-for-dev))
14
+ - Fix display of tax adjustments in checkout [#11](https://github.com/solidusio/solidus_frontend/pull/11) ([adammathys](https://github.com/adammathys))
15
+ - Utilize Rails redirect methods [#9](https://github.com/solidusio/solidus_frontend/pull/9) ([cpfergus1](https://github.com/cpfergus1))
16
+ - Bump version to 3.3.0.alpha [#6](https://github.com/solidusio/solidus_frontend/pull/6) ([waiting-for-dev](https://github.com/waiting-for-dev))
17
+
18
+ ## Solidus v3.2.5 (v3.2, 2022-12-23)
19
+
20
+ ## Solidus v3.2.4 (v3.2, 2022-11-09)
21
+
22
+ ## Solidus v3.2.3 (v3.2, 2022-11-03)
23
+
24
+ ## Solidus v3.2.2 (v3.2, 2022-09-09)
25
+
26
+ - Ask whether to add solidus_bolt during installation [#14](https://github.com/solidusio/solidus_frontend/pull/14) ([waiting-for-dev](https://github.com/waiting-for-dev))
27
+
28
+ ## Solidus v3.2.1 (v3.2, 2022-09-09)
29
+
30
+ ## Solidus v3.2.0 (v3.2, 2022-08-18)
4
31
 
5
32
  - Initial release from the standalone repository. See [Solidus'
6
33
  CHANGELOG](https://github.com/solidusio/solidus/blob/master/CHANGELOG.md) for
@@ -69,7 +69,7 @@ module Spree
69
69
  format.html do
70
70
  if @order.errors.any?
71
71
  flash[:error] = @order.errors.full_messages.join(", ")
72
- redirect_back_or_default(spree.root_path)
72
+ redirect_back(fallback_location: spree.root_path)
73
73
  return
74
74
  else
75
75
  redirect_to cart_path
@@ -45,10 +45,9 @@
45
45
  <% end %>
46
46
  <% end %>
47
47
 
48
- <% if order.adjustments.nonzero.eligible.exists? %>
48
+ <% if order.adjustments.nonzero.non_tax.eligible.exists? %>
49
49
  <tbody id="summary-order-charges" data-hook>
50
- <% order.adjustments.nonzero.eligible.each do |adjustment| %>
51
- <% next if (adjustment.source_type == 'Spree::TaxRate') and (adjustment.amount == 0) %>
50
+ <% order.adjustments.nonzero.non_tax.eligible.each do |adjustment| %>
52
51
  <tr class="total">
53
52
  <td><%= adjustment.label %>:</td>
54
53
  <td><%= adjustment.display_amount.to_html %></td>
data/bin/sandbox CHANGED
@@ -80,7 +80,7 @@ unbundled bundle exec rails generate solidus:install \
80
80
  $@
81
81
 
82
82
  unbundled bundle exec rails generate solidus:auth:install
83
- unbundled bundle exec rails generate ${extension_name}:install
83
+ unbundled bundle exec rails generate ${extension_name}:install --auto-accept
84
84
 
85
85
  echo
86
86
  echo "🚀 Sandbox app successfully created for $extension_name!"
@@ -5,10 +5,32 @@ module SolidusFrontend
5
5
  class InstallGenerator < Rails::Generators::Base
6
6
  source_root File.expand_path('templates', __dir__)
7
7
 
8
+ class_option :auto_accept,
9
+ type: :boolean,
10
+ default: false
11
+
12
+ def self.exit_on_failure?
13
+ true
14
+ end
15
+
8
16
  def copy_initializer
9
17
  template 'initializer.rb', 'config/initializers/solidus_frontend.rb'
10
18
  end
11
19
 
20
+ def robots_directives
21
+ FileUtils.touch "public/robots.txt"
22
+ append_file "public/robots.txt", <<-ROBOTS.strip_heredoc
23
+ User-agent: *
24
+ Disallow: /checkout
25
+ Disallow: /cart
26
+ Disallow: /orders
27
+ Disallow: /user
28
+ Disallow: /account
29
+ Disallow: /api
30
+ Disallow: /password
31
+ ROBOTS
32
+ end
33
+
12
34
  def setup_assets
13
35
  empty_directory 'app/assets/images'
14
36
 
@@ -19,6 +41,25 @@ module SolidusFrontend
19
41
  template "vendor/assets/javascripts/spree/frontend/all.js"
20
42
  template "vendor/assets/stylesheets/spree/frontend/all.css"
21
43
  end
44
+
45
+ def install_solidus_bolt
46
+ return if ENV['SKIP_SOLIDUS_BOLT'] || !File.exist?('Gemfile') || !(options[:auto_accept] || yes?(<<~MSG))
47
+ Would you like to add bolt (https://www.bolt.com) as a default payment method?
48
+
49
+ If you answer yes, solidus_bolt (https://github.com/solidusio/solidus_bolt)
50
+ will be added to the installation (y/n):
51
+ MSG
52
+
53
+ gem 'solidus_bolt'
54
+ bundle_cleanly { `bundle` }
55
+ generate 'solidus_bolt:install --auto-run-migrations'
56
+ end
57
+
58
+ private
59
+
60
+ def bundle_cleanly(&block)
61
+ Bundler.respond_to?(:with_unbundled_env) ? Bundler.with_unbundled_env(&block) : Bundler.with_clean_env(&block)
62
+ end
22
63
  end
23
64
  end
24
65
  end
@@ -2,7 +2,7 @@
2
2
 
3
3
  module Spree
4
4
  module Frontend
5
- VERSION = "3.3.0.alpha"
5
+ VERSION = "3.3.0"
6
6
 
7
7
  def self.version
8
8
  VERSION
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: solidus_frontend
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.3.0.alpha
4
+ version: 3.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Solidus Team
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-08-18 00:00:00.000000000 Z
11
+ date: 2023-01-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: solidus_api
@@ -389,7 +389,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
389
389
  - !ruby/object:Gem::Version
390
390
  version: 1.8.23
391
391
  requirements: []
392
- rubygems_version: 3.1.2
392
+ rubygems_version: 3.3.7
393
393
  signing_key:
394
394
  specification_version: 4
395
395
  summary: Legacy cart and storefront for the Solidus e-commerce project. For new Solidus