jekyll-liquid-plus 1.0.2 → 1.1.0

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,15 +1,7 @@
1
1
  ---
2
- !binary "U0hBMQ==":
3
- metadata.gz: !binary |-
4
- MmRkMmM1YTBiYTM5MTFkZTM0MTY4ODVlM2ZhMjQwOTFjZDc5NDQ5Mg==
5
- data.tar.gz: !binary |-
6
- NmI4NjljOTRkMmEyYzA4OTc1NGQzODhmZjk3Y2YwZmMyNzczZTlhOA==
7
- !binary "U0hBNTEy":
8
- metadata.gz: !binary |-
9
- ZDk4NGJmYTZhOGNhNGI2ZTc3MGZmNDUwZjdlNmUzZjEzNGU3MGY3ZmI3ZDc2
10
- NmI3ZTI1MmI3YmRkMWNlM2Q5ZmI2YjllYjEyNDM0NTZmOWYxZjFjMDVmYTll
11
- MGUzYmY1M2VhN2E1YzUxNGFjODI5MThmZmQ5NjcxYzc3YzQzNzk=
12
- data.tar.gz: !binary |-
13
- ODYzMTFjMjdkNDU0YzhkMmUxOWVjZTEwOTE0OGI3YjFlMDcwYTliNTU0MjM2
14
- N2RhZmIwZDgxNDA5MDVhMTIzMmFmN2M0ODU3YzhiN2M5NWE5ZDA5MjIxYTAy
15
- OTVkNjRlZjdjZmFlZjA0Y2IwMWYyZDJiNjdjZjQ5OTVkYmNlZjM=
2
+ SHA1:
3
+ metadata.gz: de976d38b8549a3022f3178705c3981e3638c9d0
4
+ data.tar.gz: 993189b53393131442fe4ebf8c486c3be17bcd40
5
+ SHA512:
6
+ metadata.gz: eaad7e1bad7865cb335d33753847146990891cc537e2e484c4a181a8a51c3e3224eebc2be69b76a76214736db3d743e6f0d7e7d223ecb8f7ab4b60a1e3b9ec29
7
+ data.tar.gz: 03d2e10cde1244326eec35df1b974e4846305523940f2fdb803398ef43e5e6bf80af7cc17463ddadd7cc980c8b89147600ac716eb80716b5f1d78b750091e368
@@ -1,5 +1,8 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.1.0 (2013-11-03)
4
+ - New: Render tag works with absolute paths and user relative paths.
5
+
3
6
  ## 1.0.2 (2013-11-03)
4
7
  - Speed improvement: Now caching file path existence to reduce disk checks.
5
8
 
@@ -12,7 +12,8 @@ module LiquidPlus
12
12
  end
13
13
  end
14
14
 
15
- # Allow paths to begin from the directory of the context page
15
+ # Allow paths to begin from the directory of the context page or
16
+ # have absolute paths
16
17
  #
17
18
  # Input:
18
19
  # - file: "file.html"
@@ -25,6 +26,8 @@ module LiquidPlus
25
26
  if file =~ /^\.\/(.+)/
26
27
  local_dir = File.dirname context.registers[:page]['path']
27
28
  File.join root, local_dir, $1
29
+ elsif file =~ /^[\/~]/
30
+ Pathname.new(file).expand_path
28
31
  else
29
32
  File.join root, file
30
33
  end
@@ -121,10 +121,9 @@ module LiquidPlus
121
121
  partial = Liquid::Template.parse(content)
122
122
 
123
123
  context.stack do
124
- c = context
125
- c['render'] = Jekyll::Tags::IncludeTag.new('', markup, []).parse_params(context) if @params
126
- c['page'] = c['page'].deep_merge(@local_vars) if @local_vars and @local_vars.keys.size > 0
127
- content = partial.render(c)
124
+ context['render'] = Jekyll::Tags::IncludeTag.new('', markup, []).parse_params(context) if @params
125
+ context['page'] = context['page'].deep_merge(@local_vars) if @local_vars and @local_vars.keys.size > 0
126
+ content = partial.render(context)
128
127
  end
129
128
  content
130
129
  end
@@ -1,3 +1,3 @@
1
1
  module LiquidPlus
2
- VERSION = "1.0.2"
2
+ VERSION = "1.1.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-liquid-plus
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.2
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brandon Mathis
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-11-04 00:00:00.000000000 Z
11
+ date: 2013-11-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll
@@ -56,14 +56,14 @@ dependencies:
56
56
  name: rake
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
- - - ! '>='
59
+ - - '>='
60
60
  - !ruby/object:Gem::Version
61
61
  version: '0'
62
62
  type: :development
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
- - - ! '>='
66
+ - - '>='
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0'
69
69
  description: Super powered Liquid tags for smarter Jekyll templating.
@@ -123,19 +123,19 @@ require_paths:
123
123
  - lib
124
124
  required_ruby_version: !ruby/object:Gem::Requirement
125
125
  requirements:
126
- - - ! '>='
126
+ - - '>='
127
127
  - !ruby/object:Gem::Version
128
128
  version: '0'
129
129
  required_rubygems_version: !ruby/object:Gem::Requirement
130
130
  requirements:
131
- - - ! '>='
131
+ - - '>='
132
132
  - !ruby/object:Gem::Version
133
133
  version: '0'
134
134
  requirements: []
135
135
  rubyforge_project:
136
- rubygems_version: 2.0.7
136
+ rubygems_version: 2.0.3
137
137
  signing_key:
138
138
  specification_version: 4
139
- summary: ! 'Do things easier with better versions of common liquid tags: include,
140
- capture, assign, and introducing: render, wrap, wrap_include, and more.'
139
+ summary: 'Do things easier with better versions of common liquid tags: include, capture,
140
+ assign, and introducing: render, wrap, wrap_include, and more.'
141
141
  test_files: []