jekyll-spree-client 0.1.15 → 0.1.16

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: 416bd768f1cdbf0a968e36466b0792a96f3f0ee4178b0a22654b5d82c973d170
4
- data.tar.gz: e8267b5cf04604fce87b7fab7e26725a83a62cf69d471fb966b3f7897756aead
3
+ metadata.gz: 4fae6ac8495376030f27da4d790f5935e0f20c2ada484eced1a266c98704ec82
4
+ data.tar.gz: 144cbab5df09cab4c48c1a0d2c16ee2f0a9c593e273750af346d143f9526ad24
5
5
  SHA512:
6
- metadata.gz: ce0e083f63dc3cfa20f114e4a020047c0d3c946b99efce126bf39043e11dd589d441da4988bf5d58f3b81e33375e931182340e35143f5cee9af49cb568b0fc05
7
- data.tar.gz: cbf6e5406e93e6fb7ddd3f42cffb907de583d77101369b66743cb56a01f9d0df736f999e141f9fb2a8d24e4c0e2a5a89447c9f5c4b873a2071671341a405672a
6
+ metadata.gz: ede792ab10edef6455c9a32f7eb42f5ad6dadc4e4c9ab59ebf06c141073177aec0264a6a236da51099108f66e1893ae1c9e5a51b36aeb97efc7357a92ec80176
7
+ data.tar.gz: 40b3025ef2c89824713d338cc9d9151a7c765803c90e3c16c3bf8430304e62cf63a5d7a71a547f3705786e3ac5a65808c5ba88adc01a0a0c48a40f799f12e9c1
data/README.md CHANGED
@@ -43,6 +43,7 @@ spree:
43
43
  sku_field: sku
44
44
  api_url: http://localhost:3000
45
45
  shipping_category_id: 1
46
+ store: https://your.store
46
47
  ```
47
48
 
48
49
  You can get the API key on your user profile. Pass it as the
@@ -52,7 +53,7 @@ You can get the API key on your user profile. Pass it as the
52
53
  SPREE_API_KEY="some random value generated by spree" bundle exec jekyll build
53
54
  ```
54
55
 
55
- Since v0.1.4 you can pass the store URL too, and it'll take precedence
56
+ Since v0.1.4 you can pass the API URL too, and it'll take precedence
56
57
  over `_config.yml`:
57
58
 
58
59
  ```bash
@@ -22,7 +22,7 @@ Jekyll::Hooks.register :site, :post_read do |site|
22
22
  end
23
23
 
24
24
  config = site.config['spree']&.transform_keys(&:to_sym) || {}
25
- config.merge!(site: site, api_key: ENV['SPREE_API_KEY'], spree_url: ENV['SPREE_URL'])
25
+ config.merge!(site: site, api_key: ENV['SPREE_API_KEY'], spree_url: ENV['SPREE_URL'], store: site.config['url'])
26
26
 
27
27
  client = Jekyll::SpreeClient.new **config
28
28
 
@@ -5,7 +5,7 @@ require 'spree_client'
5
5
 
6
6
  #
7
7
  module Jekyll
8
- SpreeClient = Struct.new :site, :sku_field, :api_key, :spree_url, :shipping_category_id, keyword_init: true do
8
+ SpreeClient = Struct.new :site, :sku_field, :api_key, :spree_url, :shipping_category_id, :store, keyword_init: true do
9
9
  # Products are posts with the SKU field
10
10
  #
11
11
  # @return [Array] Jekyll::Document
@@ -54,7 +54,7 @@ module Jekyll
54
54
  #
55
55
  # @return [SpreeClient::API::V1]
56
56
  def spree
57
- @spree ||= ::SpreeClient::API::V1.new **to_h.slice(:api_key, :spree_url)
57
+ @spree ||= ::SpreeClient::API::V1.new **to_h.slice(:api_key, :spree_url, :store)
58
58
  end
59
59
 
60
60
  # Localization with jekyll-locales
metadata CHANGED
@@ -1,29 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-spree-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.15
4
+ version: 0.1.16
5
5
  platform: ruby
6
6
  authors:
7
7
  - f
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-07-02 00:00:00.000000000 Z
11
+ date: 2021-07-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: spree-api-client
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: '0.2'
19
+ version: 0.2.3
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - "~>"
24
+ - - ">="
25
25
  - !ruby/object:Gem::Version
26
- version: '0.2'
26
+ version: 0.2.3
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: fast_blank
29
29
  requirement: !ruby/object:Gem::Requirement