jekyll-bookshop 2.0.0.pre.alpha.6 → 2.0.0.pre.alpha.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/jekyll-bookshop.rb +8 -8
- data/lib/jekyll-bookshop/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7cac00131ec04e5582dc6c8f89e177a3aa306abbc5c51522f0a9175af5016249
|
4
|
+
data.tar.gz: b3b97e8005d57aaef0c5b12c813c4671e07e9336b83a17ece8888ef8347e2a59
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7e9706e863b2d8b1f5b5edbe00afd8f011270faae31f4b8d0db3ab8863414e66f3c30c80a7ffcc5c1de69172846f50d5ca5c6066659050acd005e8b7babb8a14
|
7
|
+
data.tar.gz: db11956432b5a16c4b27e464c2c3de3d20f1d06128e2ce15f959c056846573e2e75e4d213bd3d822eb8b5fbecc3570a1668b4bcebe39ba5f9a3b6b6d1ab1b602
|
data/lib/jekyll-bookshop.rb
CHANGED
@@ -60,7 +60,7 @@ module JekyllBookshop
|
|
60
60
|
site = context.registers[:site]
|
61
61
|
|
62
62
|
bookshop_scss_files = []
|
63
|
-
site.config['
|
63
|
+
site.config['bookshop_base_locations']&.each do |location|
|
64
64
|
components_loc = Pathname.new(location + "/").cleanpath.to_s
|
65
65
|
scss_files = Dir.glob(components_loc + "/**/*.scss")&.collect do |scss_file|
|
66
66
|
scss_file.sub!(components_loc+"/", '').sub!(".scss", '')
|
@@ -88,25 +88,25 @@ module JekyllBookshop
|
|
88
88
|
|
89
89
|
# Add the paths to find bookshop's styles
|
90
90
|
def self.open_bookshop(site)
|
91
|
-
|
91
|
+
bookshop_base_locations = site.config['bookshop_locations']&.collect do |location|
|
92
92
|
Pathname.new("#{site.source}/#{location}/").cleanpath.to_s
|
93
93
|
end
|
94
|
-
|
94
|
+
bookshop_base_locations = bookshop_base_locations.select do |location|
|
95
95
|
Dir.exist?(location)
|
96
96
|
end
|
97
|
-
bookshop_component_locations =
|
97
|
+
bookshop_component_locations = bookshop_base_locations&.collect do |location|
|
98
98
|
Pathname.new("#{location}/components/").cleanpath.to_s
|
99
99
|
end
|
100
100
|
|
101
101
|
site.config['watch_dirs'] ||= [] # Paired with CloudCannon/jekyll-watch
|
102
|
-
site.config['watch_dirs'].push(*
|
102
|
+
site.config['watch_dirs'].push(*bookshop_base_locations);
|
103
103
|
|
104
104
|
site.config['sass'] ||= {}
|
105
105
|
site.config['sass']['load_paths'] ||= []
|
106
|
-
site.config['sass']['load_paths'].push(*
|
106
|
+
site.config['sass']['load_paths'].push(*bookshop_base_locations)
|
107
107
|
|
108
|
-
site.config['
|
109
|
-
site.config['
|
108
|
+
site.config['bookshop_base_locations'] ||= []
|
109
|
+
site.config['bookshop_base_locations'].push(*bookshop_base_locations)
|
110
110
|
|
111
111
|
site.config['bookshop_component_locations'] ||= []
|
112
112
|
site.config['bookshop_component_locations'].push(*bookshop_component_locations)
|