jekyll_flexible_include 2.0.26 → 2.0.28
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/.rubocop.yml +1 -1
- data/CHANGELOG.md +12 -0
- data/README.md +7 -2
- data/jekyll_flexible_include_plugin.gemspec +2 -0
- data/lib/flexible_include/version.rb +1 -1
- data/lib/flexible_include.rb +4 -1
- data/spec/{flexible_include_spec.rb → flexible_include/flexible_include_spec.rb} +8 -6
- data/spec/git_file_reader_spec.rb +1 -1
- data/spec/status_persistence.txt +8 -7
- metadata +31 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: aad4f68f20bd8bfa3ecfb6b6a6fac948c055c73e7c2e94264ef2b12cffaf29b0
|
|
4
|
+
data.tar.gz: 2c7ebd349122c1da2585ae6d2f948b80004578b96cc3e547ae4bb93cd98250d3
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: f9bed2a19760a80547ccc4ca2f73a870cfc5db5f4ab0220238b4d1a174073fbe21d9716a0f819f7a76e511cf6fcc3b672f851e7054d6a6f4da9e0cfa84ec0b5a
|
|
7
|
+
data.tar.gz: 579e06fdd4d002da562065048009e6234aba5ef75c56cf609c474a2f8c8ecd60d4fe9f5147b7a584d218912523d74d90d922aac5ccedb7e45aaa0e9cf4af040b
|
data/.rubocop.yml
CHANGED
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# Change Log
|
|
2
2
|
|
|
3
|
+
## 2.0.28 / 2025-11-18
|
|
4
|
+
|
|
5
|
+
* Added new dependency, [`benchmark`](https://github.com/ruby/benchmark),
|
|
6
|
+
because it will no longer be automatically included starting from Ruby 3.5.0.
|
|
7
|
+
* Windows env vars are only parsed for the `file` parameter.
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
## 2.0.27 / 2025-09-25
|
|
11
|
+
|
|
12
|
+
* Handle evaluation of Windows-style env var on a non-Windows machine #16
|
|
13
|
+
|
|
14
|
+
|
|
3
15
|
## 2.0.26 / 2025-09-13
|
|
4
16
|
|
|
5
17
|
* Replaced the CSS class `bg_yellow` with `bg_yellow_nopad`.
|
data/README.md
CHANGED
|
@@ -268,8 +268,13 @@ You can load it from your project, as shown below, or from a CDN.
|
|
|
268
268
|
|
|
269
269
|
## Additional Information
|
|
270
270
|
|
|
271
|
-
|
|
272
|
-
[Mike Slinn’s website](https://
|
|
271
|
+
The complete documentation is available on
|
|
272
|
+
[Mike Slinn’s website](https://mslinn.com/jekyll_plugins/jekyll_flexible_include.html).
|
|
273
|
+
|
|
274
|
+
Topics that are not mentioned in this `README.md` file include:
|
|
275
|
+
|
|
276
|
+
- How environment variables are expanded on Linux, Mac and Windows.
|
|
277
|
+
- Numbering lines.
|
|
273
278
|
|
|
274
279
|
|
|
275
280
|
## GitHub Pages
|
|
@@ -35,6 +35,8 @@ 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 'benchmark' # no longer automatically included starting from Ruby 3.5.0
|
|
39
|
+
spec.add_dependency 'jekyll_draft'
|
|
38
40
|
spec.add_dependency 'jekyll_from_to_until', '>= 1.0.5'
|
|
39
41
|
spec.add_dependency 'jekyll_plugin_support', '>= 3.1.1'
|
|
40
42
|
spec.add_dependency 'jekyll-sass-converter', '= 2.2.0'
|
data/lib/flexible_include.rb
CHANGED
|
@@ -37,7 +37,10 @@ module FlexibleInclude
|
|
|
37
37
|
# Look for *nix version of @path if Windows expansion did not yield a file that exists
|
|
38
38
|
def render_impl
|
|
39
39
|
setup
|
|
40
|
-
|
|
40
|
+
# First expand bash environment variables ($VAR or ${VAR})
|
|
41
|
+
path = ::JekyllSupport::JekyllPluginHelper.env_var_expand_bash(@filename, @logger)
|
|
42
|
+
# Then expand Windows environment variables (%VAR%) for file paths
|
|
43
|
+
@path = ::JekyllSupport::JekyllPluginHelper.env_var_expand_windows(path, @logger)
|
|
41
44
|
linux_path = `wslpath '#{@path}' 2>/dev/null`.chomp
|
|
42
45
|
@path = linux_path if !File.exist?(@path) && File.exist?(linux_path)
|
|
43
46
|
handle_path_types
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
require 'jekyll_plugin_support'
|
|
2
|
-
require_relative '
|
|
2
|
+
require_relative '../../lib/flexible_include'
|
|
3
3
|
|
|
4
|
-
RSpec.describe(FlexibleInclude) do
|
|
5
|
-
it 'controls access to files' do
|
|
4
|
+
RSpec.describe(FlexibleInclude::FlexibleInclude) do
|
|
5
|
+
it 'controls access to files', skip: 'Uses old ParseContext which might be helpful' do
|
|
6
6
|
ENV['FLEXIBLE_INCLUDE_PATHS'] = '~/.*:spec/.*'
|
|
7
7
|
|
|
8
8
|
described_class.send(:new, 'my_tag', '', Liquid::ParseContext.new)
|
|
@@ -11,9 +11,11 @@ RSpec.describe(FlexibleInclude) do
|
|
|
11
11
|
|
|
12
12
|
expect(described_class.access_allowed('~/.mem_settings.yaml')).to be_truthy
|
|
13
13
|
|
|
14
|
-
home_file = JekyllPluginHelper.expand_env '$HOME/.mem_settings.yaml'
|
|
15
|
-
expect(described_class.access_allowed(home_file)).to be_truthy
|
|
16
|
-
|
|
17
14
|
expect(described_class.access_allowed('/asdf')).to be_falsey
|
|
18
15
|
end
|
|
16
|
+
|
|
17
|
+
it 'controls access to git content' do
|
|
18
|
+
home_file = JekyllSupport::JekyllPluginHelper.expand_env '$HOME/.mem_settings.yaml'
|
|
19
|
+
expect(described_class.access_allowed(home_file)).to be_truthy
|
|
20
|
+
end
|
|
19
21
|
end
|
|
@@ -2,7 +2,7 @@ require 'jekyll_plugin_support'
|
|
|
2
2
|
require_relative '../lib/git_file_reader'
|
|
3
3
|
|
|
4
4
|
RSpec.describe(GitFileReader) do
|
|
5
|
-
it 'reads a file at a tag' do
|
|
5
|
+
it 'reads a file at a tag', skip: 'unfinished' do
|
|
6
6
|
content = described_class.new('.').blob_at('v2.0.20', 'README.md').content
|
|
7
7
|
expect(content).to include('Added `highlight` regex option')
|
|
8
8
|
|
data/spec/status_persistence.txt
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
example_id
|
|
2
|
-
|
|
3
|
-
./spec/flexible_include_spec.rb[1:1] |
|
|
4
|
-
./spec/
|
|
5
|
-
./spec/git_file_reader_spec.rb[1:
|
|
6
|
-
./spec/git_file_reader_spec.rb[1:
|
|
7
|
-
./spec/git_file_reader_spec.rb[1:
|
|
1
|
+
example_id | status | run_time |
|
|
2
|
+
----------------------------------------------------- | ------- | --------------- |
|
|
3
|
+
./spec/flexible_include/flexible_include_spec.rb[1:1] | pending | 0.00001 seconds |
|
|
4
|
+
./spec/flexible_include/flexible_include_spec.rb[1:2] | passed | 0.00125 seconds |
|
|
5
|
+
./spec/git_file_reader_spec.rb[1:1] | pending | 0.00006 seconds |
|
|
6
|
+
./spec/git_file_reader_spec.rb[1:2] | passed | 0.03572 seconds |
|
|
7
|
+
./spec/git_file_reader_spec.rb[1:3] | passed | 0.01804 seconds |
|
|
8
|
+
./spec/git_file_reader_spec.rb[1:4] | passed | 0.01657 seconds |
|
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.
|
|
4
|
+
version: 2.0.28
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Mike Slinn
|
|
@@ -11,6 +11,34 @@ bindir: exe
|
|
|
11
11
|
cert_chain: []
|
|
12
12
|
date: 1980-01-02 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
|
+
- !ruby/object:Gem::Dependency
|
|
15
|
+
name: benchmark
|
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
|
17
|
+
requirements:
|
|
18
|
+
- - ">="
|
|
19
|
+
- !ruby/object:Gem::Version
|
|
20
|
+
version: '0'
|
|
21
|
+
type: :runtime
|
|
22
|
+
prerelease: false
|
|
23
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
24
|
+
requirements:
|
|
25
|
+
- - ">="
|
|
26
|
+
- !ruby/object:Gem::Version
|
|
27
|
+
version: '0'
|
|
28
|
+
- !ruby/object:Gem::Dependency
|
|
29
|
+
name: jekyll_draft
|
|
30
|
+
requirement: !ruby/object:Gem::Requirement
|
|
31
|
+
requirements:
|
|
32
|
+
- - ">="
|
|
33
|
+
- !ruby/object:Gem::Version
|
|
34
|
+
version: '0'
|
|
35
|
+
type: :runtime
|
|
36
|
+
prerelease: false
|
|
37
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
38
|
+
requirements:
|
|
39
|
+
- - ">="
|
|
40
|
+
- !ruby/object:Gem::Version
|
|
41
|
+
version: '0'
|
|
14
42
|
- !ruby/object:Gem::Dependency
|
|
15
43
|
name: jekyll_from_to_until
|
|
16
44
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -89,7 +117,7 @@ files:
|
|
|
89
117
|
- lib/flexible_include_class.rb
|
|
90
118
|
- lib/flexible_include_private_methods.rb
|
|
91
119
|
- lib/git_file_reader.rb
|
|
92
|
-
- spec/flexible_include_spec.rb
|
|
120
|
+
- spec/flexible_include/flexible_include_spec.rb
|
|
93
121
|
- spec/git_file_reader_spec.rb
|
|
94
122
|
- spec/spec_helper.rb
|
|
95
123
|
- spec/status_persistence.txt
|
|
@@ -125,7 +153,7 @@ specification_version: 4
|
|
|
125
153
|
summary: Jekyll plugin supports various ways to include content into the generated
|
|
126
154
|
site.
|
|
127
155
|
test_files:
|
|
128
|
-
- spec/flexible_include_spec.rb
|
|
156
|
+
- spec/flexible_include/flexible_include_spec.rb
|
|
129
157
|
- spec/git_file_reader_spec.rb
|
|
130
158
|
- spec/spec_helper.rb
|
|
131
159
|
- spec/status_persistence.txt
|