jekyll_all_collections 0.2.0 → 0.2.2

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: '0028eabf4e3d4acb900fb4f8896aa40511b30c455aac9f8fe8fcd8f01705b8cc'
4
- data.tar.gz: cdd9c792fb62ee38e902d211d8860a2dd97dde34ed4268011f24269d752c71dd
3
+ metadata.gz: 98b56451934bb754055fc2f68ab03a6824f58c360eb88f739afac26c4f9a8c1e
4
+ data.tar.gz: f4295f066d3913b85d920648d66f10e9b58da55f7fd1d67681f002235aa5e249
5
5
  SHA512:
6
- metadata.gz: 667804cdfa3f061556503396219dd6e849da04420d1b778bd47c084828e7ef491dcfcb632198131913207a3f97c39ee123933b63d5922c86866c59dd210a1713
7
- data.tar.gz: 6363d5ad42d2f3b61a548ebace5c0e54e15867c48066848d821cbf004d22ef80ec3a95ae0009d1896effed76d35ec441a64bbc6d0ca0b140833043be5e32a7d1
6
+ metadata.gz: a103a3208ae1142f98ff5a6316c01502a59b1c96cf6fc2ff3c094b6200d8adb6b16d9b8d585cf28aa8448b0c2fb5df68ffdf9b01d431e21243636b1b9e8ad1e2
7
+ data.tar.gz: 60093b3825053c854cc7ef89b6ad88bd97d8a31baa231c9386e16b2810a9266df7c6a94d189260471b2d29aeba9c2dcfeb9c6faf27b81f92df5dcfde558e11e0
data/CHANGELOG.md CHANGED
@@ -1,3 +1,9 @@
1
+ ## 0.2.2 / 2023-02-12
2
+ * Updated dependency `'jekyll_plugin_support', '~> 0.4.0'`
3
+
4
+ ## 0.2.1 / 2023-02-12
5
+ * Reduced the verbosity of log output from `info` to `debug`
6
+
1
7
  ## 0.2.0 / 2023-02-04
2
8
  * Returns Array[APage] instead of a collection of different types of objects.
3
9
  * Converted the plugin to a `:site, :post_read` hook instead of a tag,
data/README.md CHANGED
@@ -189,6 +189,13 @@ Now point your web browser to http://localhost:4444
189
189
 
190
190
 
191
191
  ## Debugging
192
+ You can control the verbosity of log output by adding the following to `_config.yml` in your Jekyll project:
193
+ ```yaml
194
+ plugin_loggers:
195
+ AllCollectionsTag::AllCollectionsTag: warn
196
+ ```
197
+
198
+
192
199
  1. You have two options for initiating a debug session:
193
200
 
194
201
  1. Run `demo/_bin/debug`, without the `-r` options shown above.
@@ -31,5 +31,5 @@ Gem::Specification.new do |spec|
31
31
 
32
32
  spec.add_dependency 'jekyll', '>= 3.5.0'
33
33
  spec.add_dependency 'jekyll_draft', '~>1.1.0'
34
- spec.add_dependency 'jekyll_plugin_support', '~> 0.3.1'
34
+ spec.add_dependency 'jekyll_plugin_support', '~> 0.4.0'
35
35
  end
@@ -34,8 +34,8 @@ module AllCollectionsTag
34
34
  sort_by = (sort_by_param&.gsub(' ', '')&.split(',') if sort_by_param != false) || ['-date']
35
35
  @heading = @helper.parameter_specified?('heading') || self.class.default_head(sort_by)
36
36
  sort_lambda_string = self.class.create_lambda_string(sort_by)
37
- @logger.info "#{@page['path']} sort_by_param=#{sort_by_param}"
38
- @logger.info " sort_lambda_string = #{sort_lambda_string}\n"
37
+ @logger.debug "#{@page['path']} sort_by_param=#{sort_by_param}"
38
+ @logger.debug " sort_lambda_string = #{sort_lambda_string}\n"
39
39
  sort_lambda = self.class.evaluate(sort_lambda_string)
40
40
  generate_output(sort_lambda)
41
41
  end
@@ -94,19 +94,19 @@ module AllCollectionsTag
94
94
  id = @id.to_s.empty? ? '' : " id='#{@id}'"
95
95
  heading = @heading.to_s.empty? ? '' : "<h2#{id}>#{@heading}</h2>"
96
96
  @site.all_collections.each do |post|
97
- # @logger.info "#{post.relative_path}: last_modified=#{post.last_modified}(#{post.last_modified.class}) date=#{post.date}(#{post.date.class})"
98
- @logger.info "Error: #{post.relative_path} has no value for last_modified" if post.last_modified.to_s.empty?
97
+ # @logger.debug "#{post.relative_path}: last_modified=#{post.last_modified}(#{post.last_modified.class}) date=#{post.date}(#{post.date.class})"
98
+ @logger.debug "Error: #{post.relative_path} has no value for last_modified" if post.last_modified.to_s.empty?
99
99
  end
100
100
  collection = @site.all_collections.sort(&sort_lambda)
101
101
  <<~END_TEXT
102
102
  #{heading}
103
103
  <div class="posts">
104
104
  #{(collection.map do |post|
105
- @logger.info { " post.last_modified='#{post.last_modified}' @date_column='#{@date_column}'" }
105
+ @logger.debug { " post.last_modified='#{post.last_modified}' @date_column='#{@date_column}'" }
106
106
  date = (@date_column == 'last_modified' ? post.last_modified : post.date).strftime('%Y-%m-%d')
107
107
  draft = post.draft ? "<i class='jekyll_draft'>Draft</i>" : ''
108
108
  href = "<a href='#{post.url}'>#{post.title}</a>"
109
- @logger.info { " date='#{date}' #{post.title}\n" }
109
+ @logger.debug { " date='#{date}' #{post.title}\n" }
110
110
  " <span>#{date}</span><span>#{href}#{draft}</span>"
111
111
  end).join("\n")}
112
112
  </div>
@@ -1,3 +1,3 @@
1
1
  module JekyllAllCollectionsVersion
2
- VERSION = '0.2.0'.freeze
2
+ VERSION = '0.2.2'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll_all_collections
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mike Slinn
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-02-10 00:00:00.000000000 Z
11
+ date: 2023-02-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll
@@ -44,14 +44,14 @@ dependencies:
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: 0.3.1
47
+ version: 0.4.0
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: 0.3.1
54
+ version: 0.4.0
55
55
  description: 'Provides a collection of all collections in site.all_collections.
56
56
 
57
57
  '