jekyll 2.2.0 → 2.3.0

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of jekyll might be problematic. Click here for more details.

Files changed (306) hide show
  1. checksums.yaml +4 -4
  2. data/README.markdown +1 -1
  3. data/lib/jekyll.rb +0 -1
  4. data/lib/jekyll/collection.rb +18 -3
  5. data/lib/jekyll/command.rb +0 -25
  6. data/lib/jekyll/commands/build.rb +7 -2
  7. data/lib/jekyll/commands/help.rb +33 -0
  8. data/lib/jekyll/configuration.rb +36 -28
  9. data/lib/jekyll/converters/markdown/kramdown_parser.rb +1 -1
  10. data/lib/jekyll/convertible.rb +43 -20
  11. data/lib/jekyll/deprecator.rb +15 -8
  12. data/lib/jekyll/document.rb +21 -4
  13. data/lib/jekyll/filters.rb +27 -1
  14. data/lib/jekyll/frontmatter_defaults.rb +46 -12
  15. data/lib/jekyll/plugin.rb +10 -1
  16. data/lib/jekyll/post.rb +6 -13
  17. data/lib/jekyll/related_posts.rb +2 -2
  18. data/lib/jekyll/renderer.rb +7 -2
  19. data/lib/jekyll/site.rb +5 -7
  20. data/lib/jekyll/static_file.rb +24 -4
  21. data/lib/jekyll/tags/include.rb +3 -1
  22. data/lib/jekyll/tags/post_url.rb +2 -2
  23. data/lib/jekyll/utils.rb +88 -69
  24. data/lib/jekyll/version.rb +1 -1
  25. data/lib/site_template/_config.yml +6 -4
  26. data/lib/site_template/_includes/footer.html +43 -49
  27. data/lib/site_template/_includes/head.html +3 -4
  28. data/lib/site_template/_includes/header.html +9 -10
  29. data/lib/site_template/_layouts/default.html +6 -5
  30. data/lib/site_template/_layouts/page.html +3 -3
  31. data/lib/site_template/_layouts/post.html +4 -4
  32. data/lib/site_template/_posts/0000-00-00-welcome-to-jekyll.markdown.erb +6 -5
  33. data/lib/site_template/_sass/_base.scss +203 -0
  34. data/lib/site_template/_sass/_layout.scss +236 -0
  35. data/lib/site_template/_sass/_syntax-highlighting.scss +67 -0
  36. data/lib/site_template/css/main.scss +49 -0
  37. data/lib/site_template/feed.xml +1 -1
  38. data/lib/site_template/index.html +7 -4
  39. metadata +24 -431
  40. data/.gitignore +0 -15
  41. data/.travis.yml +0 -27
  42. data/CONTRIBUTING.markdown +0 -91
  43. data/Gemfile +0 -2
  44. data/History.markdown +0 -1310
  45. data/Rakefile +0 -268
  46. data/cucumber.yml +0 -3
  47. data/docs/jp/CONTRIBUTING.jp.markdown +0 -93
  48. data/docs/jp/README.jp.markdown +0 -68
  49. data/features/collections.feature +0 -145
  50. data/features/create_sites.feature +0 -158
  51. data/features/data.feature +0 -105
  52. data/features/drafts.feature +0 -46
  53. data/features/embed_filters.feature +0 -107
  54. data/features/frontmatter_defaults.feature +0 -136
  55. data/features/include_tag.feature +0 -68
  56. data/features/markdown.feature +0 -67
  57. data/features/pagination.feature +0 -82
  58. data/features/permalinks.feature +0 -85
  59. data/features/post_data.feature +0 -261
  60. data/features/post_excerpts.feature +0 -50
  61. data/features/rendering.feature +0 -34
  62. data/features/site_configuration.feature +0 -283
  63. data/features/site_data.feature +0 -107
  64. data/features/step_definitions/jekyll_steps.rb +0 -201
  65. data/features/support/env.rb +0 -65
  66. data/jekyll.gemspec +0 -66
  67. data/lib/site_template/css/main.css +0 -410
  68. data/script/bootstrap +0 -4
  69. data/script/branding +0 -11
  70. data/script/cibuild +0 -7
  71. data/script/console +0 -38
  72. data/script/proof +0 -22
  73. data/script/rebund +0 -140
  74. data/script/test +0 -17
  75. data/site/.gitignore +0 -4
  76. data/site/CNAME +0 -1
  77. data/site/README +0 -1
  78. data/site/_config.yml +0 -9
  79. data/site/_data/docs.yml +0 -46
  80. data/site/_includes/analytics.html +0 -30
  81. data/site/_includes/anchor_links.html +0 -32
  82. data/site/_includes/css/font-awesome.css +0 -44
  83. data/site/_includes/css/gridism.css +0 -110
  84. data/site/_includes/css/normalize.css +0 -1
  85. data/site/_includes/css/pygments.css +0 -72
  86. data/site/_includes/css/style.css +0 -1045
  87. data/site/_includes/docs_contents.html +0 -8
  88. data/site/_includes/docs_contents_mobile.html +0 -10
  89. data/site/_includes/docs_option.html +0 -11
  90. data/site/_includes/docs_ul.html +0 -20
  91. data/site/_includes/footer.html +0 -15
  92. data/site/_includes/header.html +0 -18
  93. data/site/_includes/news_contents.html +0 -33
  94. data/site/_includes/news_contents_mobile.html +0 -11
  95. data/site/_includes/news_item.html +0 -24
  96. data/site/_includes/primary-nav-items.html +0 -17
  97. data/site/_includes/section_nav.html +0 -22
  98. data/site/_includes/top.html +0 -17
  99. data/site/_layouts/default.html +0 -13
  100. data/site/_layouts/docs.html +0 -23
  101. data/site/_layouts/news.html +0 -19
  102. data/site/_layouts/news_item.html +0 -27
  103. data/site/_posts/2013-05-06-jekyll-1-0-0-released.markdown +0 -23
  104. data/site/_posts/2013-05-08-jekyll-1-0-1-released.markdown +0 -27
  105. data/site/_posts/2013-05-12-jekyll-1-0-2-released.markdown +0 -28
  106. data/site/_posts/2013-06-07-jekyll-1-0-3-released.markdown +0 -25
  107. data/site/_posts/2013-07-14-jekyll-1-1-0-released.markdown +0 -27
  108. data/site/_posts/2013-07-24-jekyll-1-1-1-released.markdown +0 -31
  109. data/site/_posts/2013-07-25-jekyll-1-0-4-released.markdown +0 -20
  110. data/site/_posts/2013-07-25-jekyll-1-1-2-released.markdown +0 -20
  111. data/site/_posts/2013-09-06-jekyll-1-2-0-released.markdown +0 -23
  112. data/site/_posts/2013-09-14-jekyll-1-2-1-released.markdown +0 -19
  113. data/site/_posts/2013-10-28-jekyll-1-3-0-rc1-released.markdown +0 -19
  114. data/site/_posts/2013-11-04-jekyll-1-3-0-released.markdown +0 -43
  115. data/site/_posts/2013-11-26-jekyll-1-3-1-released.markdown +0 -21
  116. data/site/_posts/2013-12-07-jekyll-1-4-0-released.markdown +0 -30
  117. data/site/_posts/2013-12-09-jekyll-1-4-1-released.markdown +0 -20
  118. data/site/_posts/2013-12-16-jekyll-1-4-2-released.markdown +0 -18
  119. data/site/_posts/2014-01-13-jekyll-1-4-3-released.markdown +0 -26
  120. data/site/_posts/2014-03-24-jekyll-1-5-0-released.markdown +0 -19
  121. data/site/_posts/2014-03-27-jekyll-1-5-1-released.markdown +0 -26
  122. data/site/_posts/2014-05-06-jekyll-turns-2-0-0.markdown +0 -31
  123. data/site/_posts/2014-05-08-jekyll-2-0-3-released.markdown +0 -18
  124. data/site/_posts/2014-06-04-jekyll-stickers-1-dollar-stickermule.markdown +0 -19
  125. data/site/_posts/2014-06-28-jekyll-turns-21-i-mean-2-1-0.markdown +0 -31
  126. data/site/_posts/2014-07-01-jekyll-2-1-1-released.markdown +0 -30
  127. data/site/_posts/2014-07-29-jekyll-2-2-0-released.markdown +0 -19
  128. data/site/css/screen.css +0 -31
  129. data/site/docs/assets.md +0 -66
  130. data/site/docs/collections.md +0 -259
  131. data/site/docs/configuration.md +0 -536
  132. data/site/docs/continuous-integration.md +0 -177
  133. data/site/docs/contributing.md +0 -133
  134. data/site/docs/datafiles.md +0 -108
  135. data/site/docs/deployment-methods.md +0 -127
  136. data/site/docs/drafts.md +0 -21
  137. data/site/docs/extras.md +0 -18
  138. data/site/docs/frontmatter.md +0 -191
  139. data/site/docs/github-pages.md +0 -91
  140. data/site/docs/history.md +0 -1514
  141. data/site/docs/index.md +0 -58
  142. data/site/docs/installation.md +0 -106
  143. data/site/docs/migrations.md +0 -11
  144. data/site/docs/pages.md +0 -86
  145. data/site/docs/pagination.md +0 -212
  146. data/site/docs/permalinks.md +0 -188
  147. data/site/docs/plugins.md +0 -561
  148. data/site/docs/posts.md +0 -211
  149. data/site/docs/quickstart.md +0 -26
  150. data/site/docs/resources.md +0 -43
  151. data/site/docs/sites.md +0 -29
  152. data/site/docs/structure.md +0 -190
  153. data/site/docs/templates.md +0 -376
  154. data/site/docs/troubleshooting.md +0 -147
  155. data/site/docs/upgrading.md +0 -146
  156. data/site/docs/usage.md +0 -74
  157. data/site/docs/variables.md +0 -382
  158. data/site/docs/windows.md +0 -44
  159. data/site/favicon.ico +0 -0
  160. data/site/feed.xml +0 -48
  161. data/site/fonts/FontAwesome.otf +0 -0
  162. data/site/fonts/fontawesome-webfont.eot +0 -0
  163. data/site/fonts/fontawesome-webfont.svg +0 -504
  164. data/site/fonts/fontawesome-webfont.ttf +0 -0
  165. data/site/fonts/fontawesome-webfont.woff +0 -0
  166. data/site/freenode.txt +0 -1
  167. data/site/img/article-footer.png +0 -0
  168. data/site/img/footer-arrow.png +0 -0
  169. data/site/img/footer-logo.png +0 -0
  170. data/site/img/jekyll-sticker.jpg +0 -0
  171. data/site/img/logo-2x.png +0 -0
  172. data/site/img/logo-rss.png +0 -0
  173. data/site/img/octojekyll.png +0 -0
  174. data/site/index.html +0 -90
  175. data/site/js/html5shiv.min.js +0 -4
  176. data/site/js/respond.min.js +0 -5
  177. data/site/news/index.html +0 -10
  178. data/site/news/releases/index.html +0 -10
  179. data/test/fixtures/broken_front_matter1.erb +0 -5
  180. data/test/fixtures/broken_front_matter2.erb +0 -4
  181. data/test/fixtures/broken_front_matter3.erb +0 -7
  182. data/test/fixtures/exploit_front_matter.erb +0 -4
  183. data/test/fixtures/front_matter.erb +0 -4
  184. data/test/helper.rb +0 -80
  185. data/test/source/+/%# +.md +0 -6
  186. data/test/source/+/foo.md +0 -7
  187. data/test/source/.htaccess +0 -8
  188. data/test/source/_config.dev.toml +0 -2
  189. data/test/source/_data/categories/dairy.yaml +0 -6
  190. data/test/source/_data/languages.yml +0 -2
  191. data/test/source/_data/members.json +0 -12
  192. data/test/source/_data/members.yaml +0 -7
  193. data/test/source/_data/products.yml +0 -4
  194. data/test/source/_drafts/draft-properties.text +0 -11
  195. data/test/source/_includes/include.html +0 -1
  196. data/test/source/_includes/params.html +0 -7
  197. data/test/source/_includes/sig.markdown +0 -3
  198. data/test/source/_layouts/default.html +0 -27
  199. data/test/source/_layouts/post/simple.html +0 -1
  200. data/test/source/_layouts/simple.html +0 -1
  201. data/test/source/_methods/_do_not_read_me.md +0 -5
  202. data/test/source/_methods/configuration.md +0 -8
  203. data/test/source/_methods/sanitized_path.md +0 -5
  204. data/test/source/_methods/site/_dont_include_me_either.md +0 -5
  205. data/test/source/_methods/site/generate.md +0 -6
  206. data/test/source/_methods/site/initialize.md +0 -4
  207. data/test/source/_methods/um_hi.md +0 -6
  208. data/test/source/_plugins/dummy.rb +0 -8
  209. data/test/source/_posts/2008-02-02-not-published.textile +0 -8
  210. data/test/source/_posts/2008-02-02-published.textile +0 -8
  211. data/test/source/_posts/2008-10-18-foo-bar.textile +0 -8
  212. data/test/source/_posts/2008-11-21-complex.textile +0 -8
  213. data/test/source/_posts/2008-12-03-permalinked-post.textile +0 -9
  214. data/test/source/_posts/2008-12-13-include.markdown +0 -8
  215. data/test/source/_posts/2009-01-27-array-categories.textile +0 -10
  216. data/test/source/_posts/2009-01-27-categories.textile +0 -7
  217. data/test/source/_posts/2009-01-27-category.textile +0 -7
  218. data/test/source/_posts/2009-01-27-empty-categories.textile +0 -7
  219. data/test/source/_posts/2009-01-27-empty-category.textile +0 -7
  220. data/test/source/_posts/2009-01-27-no-category.textile +0 -6
  221. data/test/source/_posts/2009-03-12-hash-#1.markdown +0 -6
  222. data/test/source/_posts/2009-05-18-empty-tag.textile +0 -6
  223. data/test/source/_posts/2009-05-18-empty-tags.textile +0 -6
  224. data/test/source/_posts/2009-05-18-tag.textile +0 -6
  225. data/test/source/_posts/2009-05-18-tags.textile +0 -9
  226. data/test/source/_posts/2009-06-22-empty-yaml.textile +0 -3
  227. data/test/source/_posts/2009-06-22-no-yaml.textile +0 -1
  228. data/test/source/_posts/2010-01-08-triple-dash.markdown +0 -5
  229. data/test/source/_posts/2010-01-09-date-override.textile +0 -7
  230. data/test/source/_posts/2010-01-09-time-override.textile +0 -7
  231. data/test/source/_posts/2010-01-09-timezone-override.textile +0 -7
  232. data/test/source/_posts/2010-01-16-override-data.textile +0 -4
  233. data/test/source/_posts/2011-04-12-md-extension.md +0 -7
  234. data/test/source/_posts/2011-04-12-text-extension.text +0 -0
  235. data/test/source/_posts/2013-01-02-post-excerpt.markdown +0 -14
  236. data/test/source/_posts/2013-01-12-nil-layout.textile +0 -6
  237. data/test/source/_posts/2013-01-12-no-layout.textile +0 -5
  238. data/test/source/_posts/2013-03-19-not-a-post.markdown/.gitkeep +0 -0
  239. data/test/source/_posts/2013-04-11-custom-excerpt.markdown +0 -10
  240. data/test/source/_posts/2013-05-10-number-category.textile +0 -7
  241. data/test/source/_posts/2013-07-22-post-excerpt-with-layout.markdown +0 -23
  242. data/test/source/_posts/2013-08-01-mkdn-extension.mkdn +0 -0
  243. data/test/source/_posts/2013-12-17-include-variable-filters.markdown +0 -21
  244. data/test/source/_posts/2013-12-20-properties.text +0 -11
  245. data/test/source/_posts/2014-01-06-permalink-traversal.md +0 -5
  246. data/test/source/_posts/2014-03-03-yaml-with-dots.md +0 -5
  247. data/test/source/_posts/2014-03-22-escape-+ %20[].markdown +0 -6
  248. data/test/source/_posts/es/2008-11-21-nested.textile +0 -8
  249. data/test/source/_sass/_grid.scss +0 -1
  250. data/test/source/_slides/example-slide-1.html +0 -4
  251. data/test/source/_slides/example-slide-2.html +0 -7
  252. data/test/source/_slides/example-slide-3.html +0 -5
  253. data/test/source/_with.dots/all.dots/2.4.0.md +0 -5
  254. data/test/source/_with.dots/file.with.dots.md +0 -0
  255. data/test/source/about.html +0 -6
  256. data/test/source/category/_posts/2008-9-23-categories.textile +0 -6
  257. data/test/source/contacts.html +0 -5
  258. data/test/source/contacts/bar.html +0 -5
  259. data/test/source/contacts/index.html +0 -5
  260. data/test/source/css/main.scss +0 -4
  261. data/test/source/css/screen.css +0 -76
  262. data/test/source/deal.with.dots.html +0 -7
  263. data/test/source/environment.html +0 -5
  264. data/test/source/exploit.md +0 -5
  265. data/test/source/foo/_posts/bar/2008-12-12-topical-post.textile +0 -8
  266. data/test/source/index.html +0 -22
  267. data/test/source/js/coffeescript.coffee +0 -10
  268. data/test/source/pgp.key +0 -2
  269. data/test/source/products.yml +0 -4
  270. data/test/source/properties.html +0 -8
  271. data/test/source/sitemap.xml +0 -32
  272. data/test/source/static_files.html +0 -4
  273. data/test/source/symlink-test/symlinked-file +0 -22
  274. data/test/source/unpublished.html +0 -7
  275. data/test/source/win/_posts/2009-05-24-yaml-linebreak.markdown +0 -7
  276. data/test/source/z_category/_posts/2008-9-23-categories.textile +0 -6
  277. data/test/suite.rb +0 -11
  278. data/test/test_cleaner.rb +0 -77
  279. data/test/test_coffeescript.rb +0 -49
  280. data/test/test_collections.rb +0 -224
  281. data/test/test_command.rb +0 -53
  282. data/test/test_configuration.rb +0 -201
  283. data/test/test_convertible.rb +0 -49
  284. data/test/test_document.rb +0 -193
  285. data/test/test_draft.rb +0 -56
  286. data/test/test_entry_filter.rb +0 -124
  287. data/test/test_excerpt.rb +0 -131
  288. data/test/test_filters.rb +0 -207
  289. data/test/test_generated_site.rb +0 -97
  290. data/test/test_kramdown.rb +0 -62
  291. data/test/test_layout_reader.rb +0 -34
  292. data/test/test_liquid_extensions.rb +0 -31
  293. data/test/test_log_adapter.rb +0 -59
  294. data/test/test_new_command.rb +0 -104
  295. data/test/test_page.rb +0 -254
  296. data/test/test_path_sanitization.rb +0 -18
  297. data/test/test_post.rb +0 -741
  298. data/test/test_rdiscount.rb +0 -22
  299. data/test/test_redcarpet.rb +0 -77
  300. data/test/test_redcloth.rb +0 -86
  301. data/test/test_related_posts.rb +0 -47
  302. data/test/test_sass.rb +0 -26
  303. data/test/test_site.rb +0 -452
  304. data/test/test_tags.rb +0 -509
  305. data/test/test_url.rb +0 -28
  306. data/test/test_utils.rb +0 -67
@@ -1,50 +0,0 @@
1
- Feature: Post excerpts
2
- As a hacker who likes to blog
3
- I want to be able to make a static site
4
- In order to share my awesome ideas with the interwebs
5
- But some people can only focus for a few moments
6
- So just give them a taste
7
-
8
- Scenario: An excerpt without a layout
9
- Given I have an "index.html" page that contains "{% for post in site.posts %}{{ post.excerpt }}{% endfor %}"
10
- And I have a _posts directory
11
- And I have the following posts:
12
- | title | date | layout | content |
13
- | entry1 | 2007-12-31 | post | content for entry1. |
14
- When I run jekyll build
15
- Then the _site directory should exist
16
- And I should see exactly "<p>content for entry1.</p>" in "_site/index.html"
17
-
18
- Scenario: An excerpt from a post with a layout
19
- Given I have an "index.html" page that contains "{% for post in site.posts %}{{ post.excerpt }}{% endfor %}"
20
- And I have a _posts directory
21
- And I have a _layouts directory
22
- And I have a post layout that contains "{{ page.excerpt }}"
23
- And I have the following posts:
24
- | title | date | layout | content |
25
- | entry1 | 2007-12-31 | post | content for entry1. |
26
- When I run jekyll build
27
- Then the _site directory should exist
28
- And the _site/2007 directory should exist
29
- And the _site/2007/12 directory should exist
30
- And the _site/2007/12/31 directory should exist
31
- And the "_site/2007/12/31/entry1.html" file should exist
32
- And I should see exactly "<p>content for entry1.</p>" in "_site/2007/12/31/entry1.html"
33
- And I should see exactly "<p>content for entry1.</p>" in "_site/index.html"
34
-
35
- Scenario: An excerpt from a post with a layout which has context
36
- Given I have an "index.html" page that contains "{% for post in site.posts %}{{ post.excerpt }}{% endfor %}"
37
- And I have a _posts directory
38
- And I have a _layouts directory
39
- And I have a post layout that contains "<html><head></head><body>{{ page.excerpt }}</body></html>"
40
- And I have the following posts:
41
- | title | date | layout | content |
42
- | entry1 | 2007-12-31 | post | content for entry1. |
43
- When I run jekyll build
44
- Then the _site directory should exist
45
- And the _site/2007 directory should exist
46
- And the _site/2007/12 directory should exist
47
- And the _site/2007/12/31 directory should exist
48
- And the "_site/2007/12/31/entry1.html" file should exist
49
- And I should see exactly "<p>content for entry1.</p>" in "_site/index.html"
50
- And I should see exactly "<html><head></head><body><p>content for entry1.</p></body></html>" in "_site/2007/12/31/entry1.html"
@@ -1,34 +0,0 @@
1
- Feature: Rendering
2
- As a hacker who likes to blog
3
- I want to be able to make a static site
4
- In order to share my awesome ideas with the interwebs
5
- But I want to make it as simply as possible
6
- So render with Liquid and place in Layouts
7
-
8
- Scenario: Render Liquid and place in layout
9
- Given I have a "index.html" page with layout "simple" that contains "Hi there, Jekyll {{ jekyll.environment }}!"
10
- And I have a simple layout that contains "{{ content }}Ahoy, indeed!"
11
- When I run jekyll build
12
- Then the _site directory should exist
13
- And I should see "Hi there, Jekyll development!\nAhoy, indeed" in "_site/index.html"
14
-
15
- Scenario: Don't place asset files in layout
16
- Given I have an "index.scss" page with layout "simple" that contains ".foo-bar { color:black; }"
17
- And I have an "index.coffee" page with layout "simple" that contains "whatever()"
18
- And I have a simple layout that contains "{{ content }}Ahoy, indeed!"
19
- When I run jekyll build
20
- Then the _site directory should exist
21
- And I should not see "Ahoy, indeed!" in "_site/index.css"
22
- And I should not see "Ahoy, indeed!" in "_site/index.js"
23
-
24
- Scenario: Don't render liquid in Sass
25
- Given I have an "index.scss" page that contains ".foo-bar { color:{{site.color}}; }"
26
- When I run jekyll build
27
- Then the _site directory should not exist
28
- And I should see "Invalid CSS after" in the build output
29
-
30
- Scenario: Don't render liquid in CoffeeScript
31
- Given I have an "index.coffee" page that contains "hey='for {{site.animal}}'"
32
- When I run jekyll build
33
- Then the _site directory should exist
34
- And I should see "hey = 'for {{site.animal}}';" in "_site/index.js"
@@ -1,283 +0,0 @@
1
- Feature: Site configuration
2
- As a hacker who likes to blog
3
- I want to be able to configure jekyll
4
- In order to make setting up a site easier
5
-
6
- Scenario: Change source directory
7
- Given I have a blank site in "_sourcedir"
8
- And I have an "_sourcedir/index.html" file that contains "Changing source directory"
9
- And I have a configuration file with "source" set to "_sourcedir"
10
- When I run jekyll build
11
- Then the _site directory should exist
12
- And I should see "Changing source directory" in "_site/index.html"
13
-
14
- Scenario: Change destination directory
15
- Given I have an "index.html" file that contains "Changing destination directory"
16
- And I have a configuration file with "destination" set to "_mysite"
17
- When I run jekyll build
18
- Then the _mysite directory should exist
19
- And I should see "Changing destination directory" in "_mysite/index.html"
20
-
21
- Scenario Outline: Similarly named source and destination
22
- Given I have a blank site in "<source>"
23
- And I have an "<source>/index.md" page that contains "markdown"
24
- And I have a configuration file with:
25
- | key | value |
26
- | source | <source> |
27
- | destination | <dest> |
28
- When I run jekyll build
29
- Then the <source> directory should exist
30
- And the "<dest>/index.html" file should <file_exist> exist
31
- And I should see "markdown" in "<source>/index.md"
32
-
33
- Examples:
34
- | source | dest | file_exist |
35
- | mysite_source | mysite | |
36
- | mysite | mysite_dest | |
37
- | mysite/ | mysite | not |
38
- | mysite | ./mysite | not |
39
- | mysite/source | mysite | not |
40
- | mysite | mysite/dest | |
41
-
42
- Scenario: Exclude files inline
43
- Given I have an "Rakefile" file that contains "I want to be excluded"
44
- And I have an "README" file that contains "I want to be excluded"
45
- And I have an "index.html" file that contains "I want to be included"
46
- And I have a configuration file with "exclude" set to "['Rakefile', 'README']"
47
- When I run jekyll build
48
- Then I should see "I want to be included" in "_site/index.html"
49
- And the "_site/Rakefile" file should not exist
50
- And the "_site/README" file should not exist
51
-
52
- Scenario: Exclude files with YAML array
53
- Given I have an "Rakefile" file that contains "I want to be excluded"
54
- And I have an "README" file that contains "I want to be excluded"
55
- And I have an "index.html" file that contains "I want to be included"
56
- And I have a configuration file with "exclude" set to:
57
- | value |
58
- | README |
59
- | Rakefile |
60
- When I run jekyll build
61
- Then I should see "I want to be included" in "_site/index.html"
62
- And the "_site/Rakefile" file should not exist
63
- And the "_site/README" file should not exist
64
-
65
- Scenario: Use RDiscount for markup
66
- Given I have an "index.markdown" page that contains "[Google](http://google.com)"
67
- And I have a configuration file with "markdown" set to "rdiscount"
68
- When I run jekyll build
69
- Then the _site directory should exist
70
- And I should see "<a href=\"http://google.com\">Google</a>" in "_site/index.html"
71
-
72
- Scenario: Use Kramdown for markup
73
- Given I have an "index.markdown" page that contains "[Google](http://google.com)"
74
- And I have a configuration file with "markdown" set to "kramdown"
75
- When I run jekyll build
76
- Then the _site directory should exist
77
- And I should see "<a href=\"http://google.com\">Google</a>" in "_site/index.html"
78
-
79
- Scenario: Use Redcarpet for markup
80
- Given I have an "index.markdown" page that contains "[Google](http://google.com)"
81
- And I have a configuration file with "markdown" set to "redcarpet"
82
- When I run jekyll build
83
- Then the _site directory should exist
84
- And I should see "<a href=\"http://google.com\">Google</a>" in "_site/index.html"
85
-
86
- Scenario: Use Maruku for markup
87
- Given I have an "index.markdown" page that contains "[Google](http://google.com)"
88
- And I have a configuration file with "markdown" set to "maruku"
89
- When I run jekyll build
90
- Then the _site directory should exist
91
- And I should see "<a href=\"http://google.com\">Google</a>" in "_site/index.html"
92
-
93
- Scenario: Highlight code with pygments
94
- Given I have an "index.html" page that contains "{% highlight ruby %} puts 'Hello world!' {% endhighlight %}"
95
- When I run jekyll build
96
- Then the _site directory should exist
97
- And I should see "Hello world!" in "_site/index.html"
98
- And I should see "class=\"highlight\"" in "_site/index.html"
99
-
100
- Scenario: Highlight code with rouge
101
- Given I have an "index.html" page that contains "{% highlight ruby %} puts 'Hello world!' {% endhighlight %}"
102
- And I have a configuration file with "highlighter" set to "rouge"
103
- When I run jekyll build
104
- Then the _site directory should exist
105
- And I should see "Hello world!" in "_site/index.html"
106
- And I should see "class=\"highlight\"" in "_site/index.html"
107
-
108
- Scenario: Rouge renders code block once
109
- Given I have a configuration file with "highlighter" set to "rouge"
110
- And I have a _posts directory
111
- And I have the following post:
112
- | title | date | layout | content |
113
- | foo | 2014-04-27 11:34 | default | {% highlight text %} test {% endhighlight %} |
114
- When I run jekyll build
115
- Then I should not see "highlight(.*)highlight" in "_site/2014/04/27/foo.html"
116
-
117
- Scenario: Set time and no future dated posts
118
- Given I have a _layouts directory
119
- And I have a page layout that contains "Page Layout: {{ site.posts.size }} on {{ site.time | date: "%Y-%m-%d" }}"
120
- And I have a post layout that contains "Post Layout: {{ content }}"
121
- And I have an "index.html" page with layout "page" that contains "site index page"
122
- And I have a configuration file with:
123
- | key | value |
124
- | time | 2010-01-01 |
125
- | future | false |
126
- And I have a _posts directory
127
- And I have the following posts:
128
- | title | date | layout | content |
129
- | entry1 | 2007-12-31 | post | content for entry1. |
130
- | entry2 | 2020-01-31 | post | content for entry2. |
131
- When I run jekyll build
132
- Then the _site directory should exist
133
- And I should see "Page Layout: 1 on 2010-01-01" in "_site/index.html"
134
- And I should see "Post Layout: <p>content for entry1.</p>" in "_site/2007/12/31/entry1.html"
135
- And the "_site/2020/01/31/entry2.html" file should not exist
136
-
137
- Scenario: Set time and future dated posts allowed
138
- Given I have a _layouts directory
139
- And I have a page layout that contains "Page Layout: {{ site.posts.size }} on {{ site.time | date: "%Y-%m-%d" }}"
140
- And I have a post layout that contains "Post Layout: {{ content }}"
141
- And I have an "index.html" page with layout "page" that contains "site index page"
142
- And I have a configuration file with:
143
- | key | value |
144
- | time | 2010-01-01 |
145
- | future | true |
146
- And I have a _posts directory
147
- And I have the following posts:
148
- | title | date | layout | content |
149
- | entry1 | 2007-12-31 | post | content for entry1. |
150
- | entry2 | 2020-01-31 | post | content for entry2. |
151
- When I run jekyll build
152
- Then the _site directory should exist
153
- And I should see "Page Layout: 2 on 2010-01-01" in "_site/index.html"
154
- And I should see "Post Layout: <p>content for entry1.</p>" in "_site/2007/12/31/entry1.html"
155
- And I should see "Post Layout: <p>content for entry2.</p>" in "_site/2020/01/31/entry2.html"
156
-
157
- Scenario: Generate proper dates with explicitly set timezone (same as posts' time)
158
- Given I have a _layouts directory
159
- And I have a page layout that contains "Page Layout: {{ site.posts.size }}"
160
- And I have a post layout that contains "Post Layout: {{ content }} built at {{ page.date | date_to_xmlschema }}"
161
- And I have an "index.html" page with layout "page" that contains "site index page"
162
- And I have a configuration file with:
163
- | key | value |
164
- | timezone | America/New_York |
165
- And I have a _posts directory
166
- And I have the following posts:
167
- | title | date | layout | content |
168
- | entry1 | 2013-04-09 23:22 -0400 | post | content for entry1. |
169
- | entry2 | 2013-04-10 03:14 -0400 | post | content for entry2. |
170
- When I run jekyll build
171
- Then the _site directory should exist
172
- And I should see "Page Layout: 2" in "_site/index.html"
173
- And I should see "Post Layout: <p>content for entry1.</p> built at 2013-04-09T23:22:00-04:00" in "_site/2013/04/09/entry1.html"
174
- And I should see "Post Layout: <p>content for entry2.</p> built at 2013-04-10T03:14:00-04:00" in "_site/2013/04/10/entry2.html"
175
-
176
- Scenario: Generate proper dates with explicitly set timezone (different than posts' time)
177
- Given I have a _layouts directory
178
- And I have a page layout that contains "Page Layout: {{ site.posts.size }}"
179
- And I have a post layout that contains "Post Layout: {{ content }} built at {{ page.date | date_to_xmlschema }}"
180
- And I have an "index.html" page with layout "page" that contains "site index page"
181
- And I have a configuration file with:
182
- | key | value |
183
- | timezone | Australia/Melbourne |
184
- And I have a _posts directory
185
- And I have the following posts:
186
- | title | date | layout | content |
187
- | entry1 | 2013-04-09 23:22 -0400 | post | content for entry1. |
188
- | entry2 | 2013-04-10 03:14 -0400 | post | content for entry2. |
189
- When I run jekyll build
190
- Then the _site directory should exist
191
- And I should see "Page Layout: 2" in "_site/index.html"
192
- And the "_site/2013/04/10/entry1.html" file should exist
193
- And the "_site/2013/04/10/entry2.html" file should exist
194
- And I should see escaped "Post Layout: <p>content for entry1.</p> built at 2013-04-10T13:22:00+10:00" in "_site/2013/04/10/entry1.html"
195
- And I should see escaped "Post Layout: <p>content for entry2.</p> built at 2013-04-10T17:14:00+10:00" in "_site/2013/04/10/entry2.html"
196
-
197
- Scenario: Limit the number of posts generated by most recent date
198
- Given I have a _posts directory
199
- And I have a configuration file with:
200
- | key | value |
201
- | limit_posts | 2 |
202
- And I have the following posts:
203
- | title | date | content |
204
- | Apples | 2009-03-27 | An article about apples |
205
- | Oranges | 2009-04-01 | An article about oranges |
206
- | Bananas | 2009-04-05 | An article about bananas |
207
- When I run jekyll build
208
- Then the _site directory should exist
209
- And the "_site/2009/04/05/bananas.html" file should exist
210
- And the "_site/2009/04/01/oranges.html" file should exist
211
- And the "_site/2009/03/27/apples.html" file should not exist
212
-
213
- Scenario: Copy over normally excluded files when they are explicitly included
214
- Given I have a ".gitignore" file that contains ".DS_Store"
215
- And I have an ".htaccess" file that contains "SomeDirective"
216
- And I have a configuration file with "include" set to:
217
- | value |
218
- | .gitignore |
219
- | .foo |
220
- When I run jekyll build
221
- Then the _site directory should exist
222
- And I should see ".DS_Store" in "_site/.gitignore"
223
- And the "_site/.htaccess" file should not exist
224
-
225
- Scenario: Using a different layouts directory
226
- Given I have a _theme directory
227
- And I have a page theme that contains "Page Layout: {{ site.posts.size }} on {{ site.time | date: "%Y-%m-%d" }}"
228
- And I have a post theme that contains "Post Layout: {{ content }}"
229
- And I have an "index.html" page with layout "page" that contains "site index page"
230
- And I have a configuration file with:
231
- | key | value |
232
- | time | 2010-01-01 |
233
- | future | true |
234
- | layouts | _theme |
235
- And I have a _posts directory
236
- And I have the following posts:
237
- | title | date | layout | content |
238
- | entry1 | 2007-12-31 | post | content for entry1. |
239
- | entry2 | 2020-01-31 | post | content for entry2. |
240
- When I run jekyll build
241
- Then the _site directory should exist
242
- And I should see "Page Layout: 2 on 2010-01-01" in "_site/index.html"
243
- And I should see "Post Layout: <p>content for entry1.</p>" in "_site/2007/12/31/entry1.html"
244
- And I should see "Post Layout: <p>content for entry2.</p>" in "_site/2020/01/31/entry2.html"
245
-
246
- Scenario: Add a gem-based plugin
247
- Given I have an "index.html" file that contains "Whatever"
248
- And I have a configuration file with "gems" set to "[jekyll_test_plugin]"
249
- When I run jekyll build
250
- Then the _site directory should exist
251
- And I should see "Whatever" in "_site/index.html"
252
- And I should see "this is a test" in "_site/test.txt"
253
-
254
- Scenario: Add an empty whitelist to restrict all gems
255
- Given I have an "index.html" file that contains "Whatever"
256
- And I have a configuration file with:
257
- | key | value |
258
- | gems | [jekyll_test_plugin] |
259
- | whitelist | [] |
260
- When I run jekyll build --safe
261
- Then the _site directory should exist
262
- And I should see "Whatever" in "_site/index.html"
263
- And the "_site/test.txt" file should not exist
264
-
265
- Scenario: Add a whitelist to restrict some gems but allow others
266
- Given I have an "index.html" file that contains "Whatever"
267
- And I have a configuration file with:
268
- | key | value |
269
- | gems | [jekyll_test_plugin, jekyll_test_plugin_malicious] |
270
- | whitelist | [jekyll_test_plugin] |
271
- When I run jekyll build --safe
272
- Then the _site directory should exist
273
- And I should see "Whatever" in "_site/index.html"
274
- And the "_site/test.txt" file should exist
275
- And I should see "this is a test" in "_site/test.txt"
276
-
277
- Scenario: arbitrary file reads via layouts
278
- Given I have an "index.html" page with layout "page" that contains "FOO"
279
- And I have a "_config.yml" file that contains "layouts: '../../../../../../../../../../../../../../usr/include'"
280
- When I run jekyll build
281
- Then the _site directory should exist
282
- And I should see "FOO" in "_site/index.html"
283
- And I should not see " " in "_site/index.html"
@@ -1,107 +0,0 @@
1
- Feature: Site data
2
- As a hacker who likes to blog
3
- I want to be able to embed data into my site
4
- In order to make the site slightly dynamic
5
-
6
- Scenario: Use page variable in a page
7
- Given I have an "contact.html" page with title "Contact" that contains "{{ page.title }}: email@example.com"
8
- When I run jekyll build
9
- Then the _site directory should exist
10
- And I should see "Contact: email@example.com" in "_site/contact.html"
11
-
12
- Scenario Outline: Use page.path variable in a page
13
- Given I have a <dir> directory
14
- And I have a "<path>" page that contains "Source path: {{ page.path }}"
15
- When I run jekyll build
16
- Then the _site directory should exist
17
- And I should see "Source path: <path>" in "_site/<path>"
18
-
19
- Examples:
20
- | dir | path |
21
- | . | index.html |
22
- | dir | dir/about.html |
23
- | dir/nested | dir/nested/page.html |
24
-
25
- Scenario: Override page.path
26
- Given I have an "override.html" page with path "custom-override.html" that contains "Custom path: {{ page.path }}"
27
- When I run jekyll build
28
- Then the _site directory should exist
29
- And I should see "Custom path: custom-override.html" in "_site/override.html"
30
-
31
- Scenario: Use site.time variable
32
- Given I have an "index.html" page that contains "{{ site.time }}"
33
- When I run jekyll build
34
- Then the _site directory should exist
35
- And I should see today's time in "_site/index.html"
36
-
37
- Scenario: Use site.posts variable for latest post
38
- Given I have a _posts directory
39
- And I have an "index.html" page that contains "{{ site.posts.first.title }}: {{ site.posts.first.url }}"
40
- And I have the following posts:
41
- | title | date | content |
42
- | First Post | 2009-03-25 | My First Post |
43
- | Second Post | 2009-03-26 | My Second Post |
44
- | Third Post | 2009-03-27 | My Third Post |
45
- When I run jekyll build
46
- Then the _site directory should exist
47
- And I should see "Third Post: /2009/03/27/third-post.html" in "_site/index.html"
48
-
49
- Scenario: Use site.posts variable in a loop
50
- Given I have a _posts directory
51
- And I have an "index.html" page that contains "{% for post in site.posts %} {{ post.title }} {% endfor %}"
52
- And I have the following posts:
53
- | title | date | content |
54
- | First Post | 2009-03-25 | My First Post |
55
- | Second Post | 2009-03-26 | My Second Post |
56
- | Third Post | 2009-03-27 | My Third Post |
57
- When I run jekyll build
58
- Then the _site directory should exist
59
- And I should see "Third Post Second Post First Post" in "_site/index.html"
60
-
61
- Scenario: Use site.categories.code variable
62
- Given I have a _posts directory
63
- And I have an "index.html" page that contains "{% for post in site.categories.code %} {{ post.title }} {% endfor %}"
64
- And I have the following posts:
65
- | title | date | category | content |
66
- | Awesome Hack | 2009-03-26 | code | puts 'Hello World' |
67
- | Delicious Beer | 2009-03-26 | food | 1) Yuengling |
68
- When I run jekyll build
69
- Then the _site directory should exist
70
- And I should see "Awesome Hack" in "_site/index.html"
71
-
72
- Scenario: Use site.tags variable
73
- Given I have a _posts directory
74
- And I have an "index.html" page that contains "{% for post in site.tags.beer %} {{ post.content }} {% endfor %}"
75
- And I have the following posts:
76
- | title | date | tag | content |
77
- | Delicious Beer | 2009-03-26 | beer | 1) Yuengling |
78
- When I run jekyll build
79
- Then the _site directory should exist
80
- And I should see "Yuengling" in "_site/index.html"
81
-
82
- Scenario: Order Posts by name when on the same date
83
- Given I have a _posts directory
84
- And I have an "index.html" page that contains "{% for post in site.posts %}{{ post.title }}:{{ post.previous.title}},{{ post.next.title}} {% endfor %}"
85
- And I have the following posts:
86
- | title | date | content |
87
- | first | 2009-02-26 | first |
88
- | A | 2009-03-26 | A |
89
- | B | 2009-03-26 | B |
90
- | C | 2009-03-26 | C |
91
- | last | 2009-04-26 | last |
92
- When I run jekyll build
93
- Then the _site directory should exist
94
- And I should see "last:C, C:B,last B:A,C A:first,B first:,A" in "_site/index.html"
95
-
96
- Scenario: Use configuration date in site payload
97
- Given I have an "index.html" page that contains "{{ site.url }}"
98
- And I have a configuration file with "url" set to "http://example.com"
99
- When I run jekyll build
100
- Then the _site directory should exist
101
- And I should see "http://example.com" in "_site/index.html"
102
-
103
- Scenario: Access Jekyll version via jekyll.version
104
- Given I have an "index.html" page that contains "{{ jekyll.version }}"
105
- When I run jekyll build
106
- Then the _site directory should exist
107
- And I should see "\d+\.\d+\.\d+" in "_site/index.html"