octopress-ink 1.0.0.rc.62 → 1.0.0.rc.63

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
  SHA1:
3
- metadata.gz: f20493df6c84e50ab1eeadbc9db1df5bf8ad021e
4
- data.tar.gz: ae01d676ab2c7f0e319c516bbf0dc84d2fe356f8
3
+ metadata.gz: 38cbab3ab928fb591f938e1c98cb078ab6ae8c51
4
+ data.tar.gz: 88673f92bd520ed0959ebc513a8ba2f191690b6a
5
5
  SHA512:
6
- metadata.gz: 822b9533c74bf2443cb36890cf9a35bc398a129084dca0eebf91226e68a1fb862750b947cc5c3a5aabb885552230406b86b619da542287c759c78337fee5781c
7
- data.tar.gz: d955e19dd99e0f59ed8529b41515e70f2a810f28d33b1b8b7a9f1b5790d2c30dc3554785912bef193d825b1c871e8e1dfb25cbd2651c9d3e64eebc858e510bb0
6
+ metadata.gz: e0d6ccfd49f34053b397b9f8941d5082ba23b52d60dea30038776c0fff98276450487473c71e7c7fe020936ff61b896f0ae2f0cf09ce8334b532f9342c254ca1
7
+ data.tar.gz: ec2662de4ea0f38adfbde2ef333203a73f81ed0096b9e1484064cc7ebd44486f7f6f5df255e0bab143be79c5b3b1e30999b43568558c3a677ed4fa71a1ec53be
data/CHANGELOG.md CHANGED
@@ -1,5 +1,8 @@
1
1
  # Changelog
2
2
 
3
+ ### 1.0.0 RC63 - 2015-04-26
4
+ - New: Pages and Sass assets can read plugin config at {{ plugin.config_label }} instead of {{ plugins.plugin-name.config_label }}.
5
+
3
6
  ### 1.0.0 RC62 - 2015-04-25
4
7
  - Fix: octopress-autoprefixer is a runtime dependencies, not a development dependency.
5
8
 
data/lib/octopress-ink.rb CHANGED
@@ -36,6 +36,10 @@ module Octopress
36
36
  require 'octopress-ink/commands'
37
37
  end
38
38
 
39
+ if ENV['OCTODEV']
40
+ require 'octopress-debugger'
41
+ end
42
+
39
43
  @load_plugin_assets = true
40
44
 
41
45
  Plugins.reset
@@ -39,8 +39,8 @@ module Octopress
39
39
  def content
40
40
  @render ||= begin
41
41
  contents = super
42
- if asset_payload = payload
43
- Liquid::Template.parse(contents).render!(payload)
42
+ if payload
43
+ Liquid::Template.parse(contents).render!({ 'plugin' => @plugin.config }.merge(payload))
44
44
  else
45
45
  contents
46
46
  end
@@ -2,22 +2,6 @@ module Octopress
2
2
  module Ink
3
3
  class Layout < Jekyll::Layout
4
4
  include Ink::Convertible
5
-
6
- # Initialize a new Layout.
7
- #
8
- # site - The Site.
9
- # base - The String path to the source.
10
- # name - The String filename of the post file.
11
- def initialize(site, base, name)
12
- @site = site
13
- @base = base
14
- @name = name
15
-
16
- self.data = {}
17
-
18
- process(name)
19
- read_yaml(base, name)
20
- end
21
5
  end
22
6
  end
23
7
  end
@@ -10,6 +10,15 @@ module Octopress
10
10
  page_source.relative_path_from(site_source).to_s
11
11
  end
12
12
 
13
+ def render(layouts, site_payload)
14
+ site_payload = {
15
+ 'plugin' => plugin.config(data['lang'])
16
+ }.merge(site_payload)
17
+
18
+ super(layouts, site_payload)
19
+ end
20
+
21
+
13
22
  # Allow pages to read url from plugin configuration
14
23
  #
15
24
  def url
@@ -1,5 +1,5 @@
1
1
  module Octopress
2
2
  module Ink
3
- VERSION = "1.0.0.rc.62"
3
+ VERSION = "1.0.0.rc.63"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: octopress-ink
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0.rc.62
4
+ version: 1.0.0.rc.63
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brandon Mathis
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-04-23 00:00:00.000000000 Z
11
+ date: 2015-04-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll