jekyll_flexible_include 2.0.18 → 2.0.19

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d8f07914cb71b0dc833f7735175ef18ccde8357e7fcf14014d954cae6e40c5bc
4
- data.tar.gz: e077293b1be82f05dedfd02e6326c6c64d4a87895fc4d6f90cc7d532d50df857
3
+ metadata.gz: 0dda7cdd2a335fc1f4f64b9579c0b0973a3c817baee5cb3dccd45aea688081d4
4
+ data.tar.gz: 81c206fabbe87b73eaf6381e173fee3ea8dafcc3f79ce91a9a5560d6abcade49
5
5
  SHA512:
6
- metadata.gz: 2a476f8c116c18590acd67e5be96fb1d10889394f3c278cec7bb43d211be7a8f8dcacc158953c4e9bea3de29b6d32668e8d5500ae24a8a0bd405d091219ac6ff
7
- data.tar.gz: 5bd8341a6eb53a35a520791a32d79ec587169650f56d36c3d4b4aa965f6247867037253d83c677cbdae913d79b19d6a18a901a63013cc49fbc526358583bb238
6
+ metadata.gz: 879ebc1e5250526005f3712b4c12b06fc936c0687e059e7f61401ca7d0cc4f724b0c216245f6fa555db9e3743f975afe40829c7acef8aef5b709c36be62e7bb0
7
+ data.tar.gz: e68c36ccac83b91af75ac84c24ea6f43da9f757d2cd30473788b40122a65fca461694adc99e0a83cec9329e02ca241b889b3ae44a7a2dc17228bcf03012de615
data/.rubocop.yml CHANGED
@@ -5,9 +5,6 @@ require:
5
5
  - rubocop-rake
6
6
  - rubocop-rspec
7
7
 
8
- # inherit_gem:
9
- # rubocop-jekyll: .rubocop.yml
10
-
11
8
  AllCops:
12
9
  Exclude:
13
10
  - demo/_site/**/*
@@ -29,8 +26,7 @@ Layout/InitialIndentation:
29
26
 
30
27
  Layout/HashAlignment:
31
28
  EnforcedColonStyle: table
32
- Exclude:
33
- - jekyll_flexible_include_plugin.gemspec
29
+ EnforcedHashRocketStyle: table
34
30
 
35
31
  Layout/LineLength:
36
32
  Max: 150
data/CHANGELOG.md CHANGED
@@ -1,3 +1,6 @@
1
+ ## 2.0.19 / 2023-04-05
2
+ * Added attribution support
3
+
1
4
  ## 2.0.18 / 2023-03-24
2
5
  * The following are now parsed property:
3
6
  `die_on_file_error`, `die_on_path_denied`, `die_on_run_error`, `die_on_path_denied`, and `die_on_other_error`.
data/README.md CHANGED
@@ -79,6 +79,7 @@ and are not intended to be written literally.
79
79
 
80
80
 
81
81
  ### Options
82
+ * `attribution` see [`jekyll_plugin_support`](https://github.com/mslinn/jekyll_plugin_support#subclass-attribution)
82
83
  * `do_not_escape` keyword option caused the content to be included without HTML escaping it.
83
84
  By default, the included file will escape characters <code>&lt;</code>,
84
85
  <code>{</code> and <code>}</code> unless the <code>do_not_escape</code> keyword option is specified.
@@ -14,7 +14,7 @@ Gem::Specification.new do |spec| # rubocop:disable Metrics/BlockLength
14
14
  END_OF_DESC
15
15
  spec.email = ['mslinn@mslinn.com']
16
16
  spec.files = Dir['.rubocop.yml', 'LICENSE.*', 'Rakefile', '{lib,spec}/**/*', '*.gemspec', '*.md']
17
- spec.homepage = 'https://www.mslinn.com/blog/2020/10/03/jekyll-plugins.html#flexibleInclude'
17
+ spec.homepage = 'https://www.mslinn.com/jekyll/3000-jekyll-plugins.html#flexibleInclude'
18
18
  spec.license = 'MIT'
19
19
  spec.metadata = {
20
20
  'allowed_push_host' => 'https://rubygems.org',
@@ -35,6 +35,6 @@ Gem::Specification.new do |spec| # rubocop:disable Metrics/BlockLength
35
35
  spec.test_files = spec.files.grep(%r!^(test|spec|features)/!)
36
36
  spec.version = JekyllFlexibleIncludePluginVersion::VERSION
37
37
 
38
- spec.add_dependency 'jekyll_plugin_support', '~> 0.5.1'
38
+ spec.add_dependency 'jekyll_plugin_support', '~> 0.6.0'
39
39
  spec.add_dependency 'rugged'
40
40
  end
@@ -1,3 +1,3 @@
1
1
  module JekyllFlexibleIncludePluginVersion
2
- VERSION = '2.0.18'.freeze
2
+ VERSION = '2.0.19'.freeze
3
3
  end
@@ -177,7 +177,11 @@ class FlexibleInclude < JekyllSupport::JekyllTag # rubocop: disable Metrics/Clas
177
177
  contents2 = @do_not_escape ? contents : FlexibleClassMethods.escape_html(contents)
178
178
  contents2 = highlight(contents2, @highlight_pattern) if @highlight_pattern
179
179
  contents2 = FlexibleInclude.number_content(contents2) if @number_lines
180
- @pre ? wrap_in_pre(path, contents2) : contents2
180
+ result = @pre ? wrap_in_pre(path, contents2) : contents2
181
+ <<~END_OUTPUT
182
+ #{result}
183
+ #{@helper.attribute if @helper.attribution}
184
+ END_OUTPUT
181
185
  end
182
186
 
183
187
  def run(cmd)
@@ -204,6 +208,7 @@ class FlexibleInclude < JekyllSupport::JekyllTag # rubocop: disable Metrics/Clas
204
208
  end
205
209
 
206
210
  def setup
211
+ @helper.gem_file __FILE__ # Enables attribution
207
212
  self.class.security_check
208
213
 
209
214
  config = @config[JekyllFlexibleIncludeName::PLUGIN_NAME]
@@ -236,7 +241,7 @@ class FlexibleInclude < JekyllSupport::JekyllTag # rubocop: disable Metrics/Clas
236
241
  dark_label = ' darkLabel' if @dark
237
242
  <<~END_PRE
238
243
  <div class="codeLabel#{dark_label}">#{label_or_href}</div>
239
- <pre data-lt-active="false" class="maxOneScreenHigh copyContainer#{@dark}" id="#{pre_id}">#{copy_button}#{content}</pre>
244
+ <pre data-lt-active="false" class="pre_tag maxOneScreenHigh copyContainer#{@dark}" id="#{pre_id}">#{copy_button}#{content}</pre>
240
245
  END_PRE
241
246
  end
242
247
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll_flexible_include
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.18
4
+ version: 2.0.19
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mike Slinn
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: exe
12
12
  cert_chain: []
13
- date: 2023-03-24 00:00:00.000000000 Z
13
+ date: 2023-04-13 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: jekyll_plugin_support
@@ -18,14 +18,14 @@ dependencies:
18
18
  requirements:
19
19
  - - "~>"
20
20
  - !ruby/object:Gem::Version
21
- version: 0.5.1
21
+ version: 0.6.0
22
22
  type: :runtime
23
23
  prerelease: false
24
24
  version_requirements: !ruby/object:Gem::Requirement
25
25
  requirements:
26
26
  - - "~>"
27
27
  - !ruby/object:Gem::Version
28
- version: 0.5.1
28
+ version: 0.6.0
29
29
  - !ruby/object:Gem::Dependency
30
30
  name: rugged
31
31
  requirement: !ruby/object:Gem::Requirement
@@ -63,14 +63,14 @@ files:
63
63
  - spec/flexible_include_spec.rb
64
64
  - spec/spec_helper.rb
65
65
  - spec/status_persistence.txt
66
- homepage: https://www.mslinn.com/blog/2020/10/03/jekyll-plugins.html#flexibleInclude
66
+ homepage: https://www.mslinn.com/jekyll/3000-jekyll-plugins.html#flexibleInclude
67
67
  licenses:
68
68
  - MIT
69
69
  metadata:
70
70
  allowed_push_host: https://rubygems.org
71
71
  bug_tracker_uri: https://github.com/mslinn/jekyll_flexible_include_plugin/issues
72
72
  changelog_uri: https://github.com/mslinn/jekyll_flexible_include_plugin/CHANGELOG.md
73
- homepage_uri: https://www.mslinn.com/blog/2020/10/03/jekyll-plugins.html#flexibleInclude
73
+ homepage_uri: https://www.mslinn.com/jekyll/3000-jekyll-plugins.html#flexibleInclude
74
74
  source_code_uri: https://github.com/mslinn/jekyll_flexible_include_plugin
75
75
  post_install_message: |2+
76
76