octopress-ink 1.0.0.alpha.14 → 1.0.0.alpha.15

Sign up to get free protection for your applications and to get access to all the features.
Files changed (99) hide show
  1. checksums.yaml +4 -4
  2. data/.travis.yml +6 -0
  3. data/CHANGELOG.md +0 -0
  4. data/README.md +3 -0
  5. data/lib/octopress-ink/assets/asset.rb +26 -10
  6. data/lib/octopress-ink/assets/{template.rb → include.rb} +1 -1
  7. data/lib/octopress-ink/assets/sass.rb +16 -3
  8. data/lib/octopress-ink/assets.rb +1 -1
  9. data/lib/octopress-ink/plugin.rb +9 -9
  10. data/lib/octopress-ink/plugins/sass.rb +2 -0
  11. data/lib/octopress-ink/plugins.rb +48 -24
  12. data/lib/octopress-ink/tags/include.rb +32 -0
  13. data/lib/octopress-ink/tags/javascript.rb +1 -5
  14. data/lib/octopress-ink/tags/stylesheet.rb +1 -5
  15. data/lib/octopress-ink/tags/yield.rb +5 -1
  16. data/lib/octopress-ink/tags.rb +1 -1
  17. data/lib/octopress-ink/version.rb +1 -1
  18. data/lib/octopress-ink.rb +4 -2
  19. data/test/_config.yml +12 -5
  20. data/test/expected/index.html +41 -0
  21. data/test/expected/javascripts/d41d8cd98f00b204e9800998ecf8427e.js +2 -0
  22. data/test/expected/layout_tests/local.html +3 -0
  23. data/test/expected/layout_tests/plugin_layout.html +3 -0
  24. data/test/expected/layout_tests/theme.html +13 -0
  25. data/test/expected/layout_tests/theme_override.html +14 -0
  26. data/test/expected/stylesheets/all-f769b23f68363155b7ab58ba178c0f53.css +1 -0
  27. data/test/expected/stylesheets/print-8f4e66fc8350adcb4482cebe140f212d.css +1 -0
  28. data/test/expected/tag_tests/content_for.html +13 -0
  29. data/test/expected/tag_tests/footer.html +13 -0
  30. data/test/expected/tag_tests/head.html +13 -0
  31. data/test/expected/tag_tests/include.html +2 -0
  32. data/test/expected/tag_tests/include_plugin.html +1 -0
  33. data/test/expected/tag_tests/include_theme.html +2 -0
  34. data/test/expected/tag_tests/include_theme_override.html +1 -0
  35. data/test/expected/tag_tests/scripts.html +13 -0
  36. data/test/{_plugins → expected}/theme/files/test.html +0 -0
  37. data/test/site/index.html +41 -0
  38. data/test/site/javascripts/d41d8cd98f00b204e9800998ecf8427e.js +2 -0
  39. data/test/site/layout_tests/local.html +3 -0
  40. data/test/site/layout_tests/plugin_layout.html +3 -0
  41. data/test/site/layout_tests/theme.html +13 -0
  42. data/test/site/layout_tests/theme_override.html +14 -0
  43. data/test/site/stylesheets/all-f769b23f68363155b7ab58ba178c0f53.css +1 -0
  44. data/test/site/stylesheets/print-8f4e66fc8350adcb4482cebe140f212d.css +1 -0
  45. data/test/site/tag_tests/content_for.html +13 -0
  46. data/test/site/tag_tests/footer.html +13 -0
  47. data/test/site/tag_tests/head.html +13 -0
  48. data/test/site/tag_tests/include.html +2 -0
  49. data/test/site/tag_tests/include_plugin.html +1 -0
  50. data/test/site/tag_tests/include_theme.html +2 -0
  51. data/test/site/tag_tests/include_theme_override.html +1 -0
  52. data/test/site/tag_tests/scripts.html +13 -0
  53. data/test/site/theme/files/test.html +1 -0
  54. data/test/{.gitignore → source/.gitignore} +0 -0
  55. data/test/source/_custom/theme/includes/bar.html +2 -0
  56. data/test/source/_custom/theme/layouts/test.html +4 -0
  57. data/test/source/_custom/theme/stylesheets/_baz.sass +1 -0
  58. data/test/{_custom → source/_custom}/theme/stylesheets/site.css +0 -0
  59. data/test/source/_includes/foo.html +1 -0
  60. data/test/source/_layouts/default.html +12 -0
  61. data/test/source/_layouts/local.html +2 -0
  62. data/test/source/_plugins/awesome-sauce/includes/some-include.html +1 -0
  63. data/test/source/_plugins/awesome-sauce/layouts/test-layout.html +2 -0
  64. data/test/{_plugins → source/_plugins}/bundler.rb +9 -5
  65. data/test/source/_plugins/theme/files/test.html +1 -0
  66. data/test/source/_plugins/theme/includes/bar.html +2 -0
  67. data/test/source/_plugins/theme/includes/foo.html +1 -0
  68. data/test/{_plugins → source/_plugins}/theme/javascripts/bar.js +0 -0
  69. data/test/{_plugins → source/_plugins}/theme/javascripts/foo.js +0 -0
  70. data/test/{_plugins → source/_plugins}/theme/layouts/default.html +1 -7
  71. data/test/{_plugins → source/_plugins}/theme/layouts/test.html +1 -1
  72. data/test/{_plugins → source/_plugins}/theme/stylesheets/_baz.scss +0 -0
  73. data/test/{_custom → source/_plugins}/theme/stylesheets/bar.scss +0 -0
  74. data/test/{_plugins → source/_plugins}/theme/stylesheets/foo.css +0 -0
  75. data/test/{_plugins → source/_plugins}/theme/stylesheets/print.css +0 -0
  76. data/test/{_plugins → source/_plugins}/theme/stylesheets/site.css +0 -0
  77. data/test/source/index.md +20 -0
  78. data/test/source/layout_tests/local.html +4 -0
  79. data/test/source/layout_tests/plugin_layout.html +4 -0
  80. data/test/source/layout_tests/theme.html +4 -0
  81. data/test/source/layout_tests/theme_override.html +4 -0
  82. data/test/{stylesheets → source/stylesheets}/_foo.scss +0 -0
  83. data/test/{stylesheets → source/stylesheets}/site.sass +0 -0
  84. data/test/source/tag_tests/content_for.html +6 -0
  85. data/test/source/tag_tests/footer.html +6 -0
  86. data/test/source/tag_tests/head.html +10 -0
  87. data/test/source/tag_tests/include.html +3 -0
  88. data/test/source/tag_tests/include_plugin.html +3 -0
  89. data/test/source/tag_tests/include_theme.html +4 -0
  90. data/test/source/tag_tests/include_theme_override.html +3 -0
  91. data/test/source/tag_tests/scripts.html +6 -0
  92. data/test/test.rb +42 -0
  93. metadata +152 -44
  94. data/lib/octopress-ink/tags/embed.rb +0 -28
  95. data/test/_custom/theme/layouts/default.html +0 -17
  96. data/test/_custom/theme/stylesheets/_bazz.scss +0 -1
  97. data/test/_plugins/theme/embeds/foo.html +0 -1
  98. data/test/_plugins/theme/stylesheets/bar.scss +0 -4
  99. data/test/index.md +0 -13
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.alpha.14
4
+ version: 1.0.0.alpha.15
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brandon Mathis
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-01-08 00:00:00.000000000 Z
11
+ date: 2014-01-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll
@@ -74,6 +74,8 @@ extensions: []
74
74
  extra_rdoc_files: []
75
75
  files:
76
76
  - .gitignore
77
+ - .travis.yml
78
+ - CHANGELOG.md
77
79
  - Gemfile
78
80
  - LICENSE.txt
79
81
  - README.md
@@ -81,13 +83,13 @@ files:
81
83
  - lib/octopress-ink.rb
82
84
  - lib/octopress-ink/assets.rb
83
85
  - lib/octopress-ink/assets/asset.rb
86
+ - lib/octopress-ink/assets/include.rb
84
87
  - lib/octopress-ink/assets/javascript.rb
85
88
  - lib/octopress-ink/assets/layout.rb
86
89
  - lib/octopress-ink/assets/sass.rb
87
90
  - lib/octopress-ink/assets/static_file.rb
88
91
  - lib/octopress-ink/assets/static_file_content.rb
89
92
  - lib/octopress-ink/assets/stylesheet.rb
90
- - lib/octopress-ink/assets/template.rb
91
93
  - lib/octopress-ink/generators/plugin_assets.rb
92
94
  - lib/octopress-ink/helpers/content_for.rb
93
95
  - lib/octopress-ink/jekyll/hooks.rb
@@ -96,9 +98,9 @@ files:
96
98
  - lib/octopress-ink/plugins/sass.rb
97
99
  - lib/octopress-ink/tags.rb
98
100
  - lib/octopress-ink/tags/content_for.rb
99
- - lib/octopress-ink/tags/embed.rb
100
101
  - lib/octopress-ink/tags/footer.rb
101
102
  - lib/octopress-ink/tags/head.rb
103
+ - lib/octopress-ink/tags/include.rb
102
104
  - lib/octopress-ink/tags/javascript.rb
103
105
  - lib/octopress-ink/tags/scripts.rb
104
106
  - lib/octopress-ink/tags/stylesheet.rb
@@ -106,28 +108,81 @@ files:
106
108
  - lib/octopress-ink/tags/yield.rb
107
109
  - lib/octopress-ink/version.rb
108
110
  - octopress-ink.gemspec
109
- - test/.gitignore
110
111
  - test/Gemfile
111
112
  - test/_config.yml
112
- - test/_custom/theme/layouts/default.html
113
- - test/_custom/theme/stylesheets/_bazz.scss
114
- - test/_custom/theme/stylesheets/bar.scss
115
- - test/_custom/theme/stylesheets/site.css
116
- - test/_plugins/bundler.rb
117
- - test/_plugins/theme/embeds/foo.html
118
- - test/_plugins/theme/files/test.html
119
- - test/_plugins/theme/javascripts/bar.js
120
- - test/_plugins/theme/javascripts/foo.js
121
- - test/_plugins/theme/layouts/default.html
122
- - test/_plugins/theme/layouts/test.html
123
- - test/_plugins/theme/stylesheets/_baz.scss
124
- - test/_plugins/theme/stylesheets/bar.scss
125
- - test/_plugins/theme/stylesheets/foo.css
126
- - test/_plugins/theme/stylesheets/print.css
127
- - test/_plugins/theme/stylesheets/site.css
128
- - test/index.md
129
- - test/stylesheets/_foo.scss
130
- - test/stylesheets/site.sass
113
+ - test/expected/index.html
114
+ - test/expected/javascripts/d41d8cd98f00b204e9800998ecf8427e.js
115
+ - test/expected/layout_tests/local.html
116
+ - test/expected/layout_tests/plugin_layout.html
117
+ - test/expected/layout_tests/theme.html
118
+ - test/expected/layout_tests/theme_override.html
119
+ - test/expected/stylesheets/all-f769b23f68363155b7ab58ba178c0f53.css
120
+ - test/expected/stylesheets/print-8f4e66fc8350adcb4482cebe140f212d.css
121
+ - test/expected/tag_tests/content_for.html
122
+ - test/expected/tag_tests/footer.html
123
+ - test/expected/tag_tests/head.html
124
+ - test/expected/tag_tests/include.html
125
+ - test/expected/tag_tests/include_plugin.html
126
+ - test/expected/tag_tests/include_theme.html
127
+ - test/expected/tag_tests/include_theme_override.html
128
+ - test/expected/tag_tests/scripts.html
129
+ - test/expected/theme/files/test.html
130
+ - test/site/index.html
131
+ - test/site/javascripts/d41d8cd98f00b204e9800998ecf8427e.js
132
+ - test/site/layout_tests/local.html
133
+ - test/site/layout_tests/plugin_layout.html
134
+ - test/site/layout_tests/theme.html
135
+ - test/site/layout_tests/theme_override.html
136
+ - test/site/stylesheets/all-f769b23f68363155b7ab58ba178c0f53.css
137
+ - test/site/stylesheets/print-8f4e66fc8350adcb4482cebe140f212d.css
138
+ - test/site/tag_tests/content_for.html
139
+ - test/site/tag_tests/footer.html
140
+ - test/site/tag_tests/head.html
141
+ - test/site/tag_tests/include.html
142
+ - test/site/tag_tests/include_plugin.html
143
+ - test/site/tag_tests/include_theme.html
144
+ - test/site/tag_tests/include_theme_override.html
145
+ - test/site/tag_tests/scripts.html
146
+ - test/site/theme/files/test.html
147
+ - test/source/.gitignore
148
+ - test/source/_custom/theme/includes/bar.html
149
+ - test/source/_custom/theme/layouts/test.html
150
+ - test/source/_custom/theme/stylesheets/_baz.sass
151
+ - test/source/_custom/theme/stylesheets/site.css
152
+ - test/source/_includes/foo.html
153
+ - test/source/_layouts/default.html
154
+ - test/source/_layouts/local.html
155
+ - test/source/_plugins/awesome-sauce/includes/some-include.html
156
+ - test/source/_plugins/awesome-sauce/layouts/test-layout.html
157
+ - test/source/_plugins/bundler.rb
158
+ - test/source/_plugins/theme/files/test.html
159
+ - test/source/_plugins/theme/includes/bar.html
160
+ - test/source/_plugins/theme/includes/foo.html
161
+ - test/source/_plugins/theme/javascripts/bar.js
162
+ - test/source/_plugins/theme/javascripts/foo.js
163
+ - test/source/_plugins/theme/layouts/default.html
164
+ - test/source/_plugins/theme/layouts/test.html
165
+ - test/source/_plugins/theme/stylesheets/_baz.scss
166
+ - test/source/_plugins/theme/stylesheets/bar.scss
167
+ - test/source/_plugins/theme/stylesheets/foo.css
168
+ - test/source/_plugins/theme/stylesheets/print.css
169
+ - test/source/_plugins/theme/stylesheets/site.css
170
+ - test/source/index.md
171
+ - test/source/layout_tests/local.html
172
+ - test/source/layout_tests/plugin_layout.html
173
+ - test/source/layout_tests/theme.html
174
+ - test/source/layout_tests/theme_override.html
175
+ - test/source/stylesheets/_foo.scss
176
+ - test/source/stylesheets/site.sass
177
+ - test/source/tag_tests/content_for.html
178
+ - test/source/tag_tests/footer.html
179
+ - test/source/tag_tests/head.html
180
+ - test/source/tag_tests/include.html
181
+ - test/source/tag_tests/include_plugin.html
182
+ - test/source/tag_tests/include_theme.html
183
+ - test/source/tag_tests/include_theme_override.html
184
+ - test/source/tag_tests/scripts.html
185
+ - test/test.rb
131
186
  homepage: https://github.com/octopress/ink
132
187
  licenses:
133
188
  - MIT
@@ -153,25 +208,78 @@ signing_key:
153
208
  specification_version: 4
154
209
  summary: A starting point for creating gem-based Jekyll themes and plugins
155
210
  test_files:
156
- - test/.gitignore
157
211
  - test/Gemfile
158
212
  - test/_config.yml
159
- - test/_custom/theme/layouts/default.html
160
- - test/_custom/theme/stylesheets/_bazz.scss
161
- - test/_custom/theme/stylesheets/bar.scss
162
- - test/_custom/theme/stylesheets/site.css
163
- - test/_plugins/bundler.rb
164
- - test/_plugins/theme/embeds/foo.html
165
- - test/_plugins/theme/files/test.html
166
- - test/_plugins/theme/javascripts/bar.js
167
- - test/_plugins/theme/javascripts/foo.js
168
- - test/_plugins/theme/layouts/default.html
169
- - test/_plugins/theme/layouts/test.html
170
- - test/_plugins/theme/stylesheets/_baz.scss
171
- - test/_plugins/theme/stylesheets/bar.scss
172
- - test/_plugins/theme/stylesheets/foo.css
173
- - test/_plugins/theme/stylesheets/print.css
174
- - test/_plugins/theme/stylesheets/site.css
175
- - test/index.md
176
- - test/stylesheets/_foo.scss
177
- - test/stylesheets/site.sass
213
+ - test/expected/index.html
214
+ - test/expected/javascripts/d41d8cd98f00b204e9800998ecf8427e.js
215
+ - test/expected/layout_tests/local.html
216
+ - test/expected/layout_tests/plugin_layout.html
217
+ - test/expected/layout_tests/theme.html
218
+ - test/expected/layout_tests/theme_override.html
219
+ - test/expected/stylesheets/all-f769b23f68363155b7ab58ba178c0f53.css
220
+ - test/expected/stylesheets/print-8f4e66fc8350adcb4482cebe140f212d.css
221
+ - test/expected/tag_tests/content_for.html
222
+ - test/expected/tag_tests/footer.html
223
+ - test/expected/tag_tests/head.html
224
+ - test/expected/tag_tests/include.html
225
+ - test/expected/tag_tests/include_plugin.html
226
+ - test/expected/tag_tests/include_theme.html
227
+ - test/expected/tag_tests/include_theme_override.html
228
+ - test/expected/tag_tests/scripts.html
229
+ - test/expected/theme/files/test.html
230
+ - test/site/index.html
231
+ - test/site/javascripts/d41d8cd98f00b204e9800998ecf8427e.js
232
+ - test/site/layout_tests/local.html
233
+ - test/site/layout_tests/plugin_layout.html
234
+ - test/site/layout_tests/theme.html
235
+ - test/site/layout_tests/theme_override.html
236
+ - test/site/stylesheets/all-f769b23f68363155b7ab58ba178c0f53.css
237
+ - test/site/stylesheets/print-8f4e66fc8350adcb4482cebe140f212d.css
238
+ - test/site/tag_tests/content_for.html
239
+ - test/site/tag_tests/footer.html
240
+ - test/site/tag_tests/head.html
241
+ - test/site/tag_tests/include.html
242
+ - test/site/tag_tests/include_plugin.html
243
+ - test/site/tag_tests/include_theme.html
244
+ - test/site/tag_tests/include_theme_override.html
245
+ - test/site/tag_tests/scripts.html
246
+ - test/site/theme/files/test.html
247
+ - test/source/.gitignore
248
+ - test/source/_custom/theme/includes/bar.html
249
+ - test/source/_custom/theme/layouts/test.html
250
+ - test/source/_custom/theme/stylesheets/_baz.sass
251
+ - test/source/_custom/theme/stylesheets/site.css
252
+ - test/source/_includes/foo.html
253
+ - test/source/_layouts/default.html
254
+ - test/source/_layouts/local.html
255
+ - test/source/_plugins/awesome-sauce/includes/some-include.html
256
+ - test/source/_plugins/awesome-sauce/layouts/test-layout.html
257
+ - test/source/_plugins/bundler.rb
258
+ - test/source/_plugins/theme/files/test.html
259
+ - test/source/_plugins/theme/includes/bar.html
260
+ - test/source/_plugins/theme/includes/foo.html
261
+ - test/source/_plugins/theme/javascripts/bar.js
262
+ - test/source/_plugins/theme/javascripts/foo.js
263
+ - test/source/_plugins/theme/layouts/default.html
264
+ - test/source/_plugins/theme/layouts/test.html
265
+ - test/source/_plugins/theme/stylesheets/_baz.scss
266
+ - test/source/_plugins/theme/stylesheets/bar.scss
267
+ - test/source/_plugins/theme/stylesheets/foo.css
268
+ - test/source/_plugins/theme/stylesheets/print.css
269
+ - test/source/_plugins/theme/stylesheets/site.css
270
+ - test/source/index.md
271
+ - test/source/layout_tests/local.html
272
+ - test/source/layout_tests/plugin_layout.html
273
+ - test/source/layout_tests/theme.html
274
+ - test/source/layout_tests/theme_override.html
275
+ - test/source/stylesheets/_foo.scss
276
+ - test/source/stylesheets/site.sass
277
+ - test/source/tag_tests/content_for.html
278
+ - test/source/tag_tests/footer.html
279
+ - test/source/tag_tests/head.html
280
+ - test/source/tag_tests/include.html
281
+ - test/source/tag_tests/include_plugin.html
282
+ - test/source/tag_tests/include_theme.html
283
+ - test/source/tag_tests/include_theme_override.html
284
+ - test/source/tag_tests/scripts.html
285
+ - test/test.rb
@@ -1,28 +0,0 @@
1
- module Octopress
2
- module Tags
3
- class EmbedTag < Liquid::Tag
4
- EMBED_SYNTAX = /(.+?)\/(\S+)/
5
-
6
- def initialize(tag_name, markup, tokens)
7
- super
8
- @markup = markup
9
- if @markup.strip =~ EMBED_SYNTAX
10
- @plugin = $1
11
- @path = $2
12
- else
13
- raise IOError.new "Invalid Syntax: for embed tag. {% embed #{@markup.strip} %} should be {% embed plugin/file %}"
14
- end
15
- end
16
-
17
- def render(context)
18
- content = Plugins.embed(@plugin, @path, context.registers[:site]).read
19
- partial = Liquid::Template.parse(content)
20
- context.stack {
21
- context['embed'] = Jekyll::Tags::IncludeTag.new('include', @markup, []).parse_params(context)
22
- partial.render!(context)
23
- }.strip
24
- end
25
- end
26
- end
27
- end
28
-
@@ -1,17 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <meta charset="utf-8">
5
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
6
- <title>{{ page.title }}</title>
7
- <meta name="viewport" content="width=device-width">
8
- {% octopress_css %}
9
- {% yield head %}
10
- </head>
11
- <body class="dang">
12
- {{ content }}
13
- {% wrap_yield footer %}<footer>{= yield }</footer>{% endwrap_yield %}
14
- {% octopress_js %}
15
- {% yield scripts %}
16
- </body>
17
- </html>
@@ -1 +0,0 @@
1
- $bg: white;
@@ -1 +0,0 @@
1
- {{ embed.greeting }}, I heard you like embeds.
@@ -1,4 +0,0 @@
1
- @import 'baz';
2
- body {
3
- background: $bg;
4
- }
data/test/index.md DELETED
@@ -1,13 +0,0 @@
1
- ---
2
- layout: theme:default
3
- title: Your New Jekyll Site
4
- ---
5
- **Hello World!**
6
-
7
- {% head %}
8
- {% embed theme/foo.html greeting='Yo Dawg' %}
9
- {% endhead %}
10
-
11
- {% content_for footer %}
12
- **OMG**
13
- {% endcontent_for %}