middleman-core 4.3.0.rc.1 → 4.3.0.rc.2

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.
Files changed (190) hide show
  1. checksums.yaml +5 -5
  2. data/Rakefile +0 -1
  3. data/cucumber.yml +2 -2
  4. data/features/asset_hash.feature +2 -2
  5. data/features/collections.feature +2 -2
  6. data/features/i18n_mixed_sources.feature +8 -0
  7. data/features/markdown.feature +0 -1
  8. data/features/multiple-sources-reload.feature +40 -0
  9. data/features/partials.feature +1 -1
  10. data/features/support/env.rb +4 -1
  11. data/features/tilde_directories.feature +0 -2
  12. data/features/unicode_filenames.feature +1 -1
  13. data/fixtures/asset-hash-app/config.rb +0 -1
  14. data/fixtures/asset-hash-app/lib/middleware.rb +2 -2
  15. data/fixtures/asset-hash-app/source/stylesheets/_partial.sass +1 -1
  16. data/fixtures/asset-hash-prefix/config.rb +1 -2
  17. data/fixtures/asset-hash-prefix/lib/middleware.rb +2 -2
  18. data/fixtures/asset-hash-source-map/config.rb +0 -1
  19. data/fixtures/asset-hash-source-map/lib/middleware.rb +2 -2
  20. data/fixtures/asset-host-app/config.rb +1 -1
  21. data/fixtures/auto-css-app/config.rb +2 -2
  22. data/fixtures/auto-js-app/config.rb +2 -2
  23. data/fixtures/auto-js-directory-index-app/config.rb +1 -1
  24. data/fixtures/automatic-directory-matcher-app/config.rb +1 -1
  25. data/fixtures/basic-data-app/config.rb +2 -2
  26. data/fixtures/capture-html-app/config.rb +4 -4
  27. data/fixtures/clean-app/config-complications.rb +6 -6
  28. data/fixtures/clean-app/config-hidden-dir-after.rb +4 -4
  29. data/fixtures/clean-app/config-hidden-dir-before.rb +1 -1
  30. data/fixtures/clean-app/config.rb +6 -6
  31. data/fixtures/clean-dir-app/config.rb +0 -1
  32. data/fixtures/clean-nested-app/config.rb +1 -1
  33. data/fixtures/collections-app/source/blog1/2011-01-01-new-article.html.markdown +1 -1
  34. data/fixtures/collections-app/source/blog1/2011-01-02-another-article.html.markdown +1 -1
  35. data/fixtures/collections-app/source/blog2/2011-01-01-new-article.html.markdown +1 -1
  36. data/fixtures/collections-app/source/blog2/2011-01-02-another-article.html.markdown +1 -1
  37. data/fixtures/content-for-app/config.rb +4 -4
  38. data/fixtures/destination-dir-different-from-source-dir-name/external/page.html.erb +1 -0
  39. data/fixtures/destination-dir-different-from-source-dir-name/my-app/config.rb +2 -0
  40. data/fixtures/destination-dir-different-from-source-dir-name/my-app/source/index.html.erb +1 -0
  41. data/fixtures/dynamic-pages-app/config.rb +25 -26
  42. data/fixtures/ember-cli-app/config.rb +4 -4
  43. data/fixtures/env-app/environments/development.rb +1 -1
  44. data/fixtures/env-app/environments/production.rb +1 -1
  45. data/fixtures/extension-hooks-app/config.rb +8 -8
  46. data/fixtures/external-helpers/config.rb +2 -2
  47. data/fixtures/external-helpers/helpers/derp.rb +3 -1
  48. data/fixtures/external-helpers/helpers/four_helpers.rb +3 -1
  49. data/fixtures/external-helpers/helpers/one_helper.rb +3 -1
  50. data/fixtures/external-helpers/helpers/yet_another_thingy.rb +3 -1
  51. data/fixtures/external-helpers/lib/hello_helper.rb +1 -1
  52. data/fixtures/external-pipeline-error/config.rb +4 -4
  53. data/fixtures/feature-params-app/config.rb +1 -1
  54. data/fixtures/frontmatter-app/config.rb +1 -1
  55. data/fixtures/glob-app/config.rb +1 -1
  56. data/fixtures/i-8859-1-app/config.rb +1 -1
  57. data/fixtures/i18n-force-locale/config.rb +4 -4
  58. data/fixtures/i18n-mixed-sources/config.rb +1 -1
  59. data/fixtures/i18n-mixed-sources/source/c/d/index.html.erb +9 -0
  60. data/fixtures/i18n-mixed-sources/source/localizable/c/d/index.html.erb +9 -0
  61. data/fixtures/import-app/config.rb +3 -3
  62. data/fixtures/indexable-app/config.rb +3 -3
  63. data/fixtures/large-build-app/config.rb +1 -1
  64. data/fixtures/manual-layout-override/config.rb +1 -1
  65. data/fixtures/missing-tilt-library-app/config.rb +2 -2
  66. data/fixtures/more-traversal-app/config.rb +4 -4
  67. data/fixtures/multiple-data-sources-app/config.rb +1 -1
  68. data/fixtures/multiple-sources-app/config.rb +1 -1
  69. data/fixtures/multiple-sources-with-destination-dir/config.rb +2 -0
  70. data/fixtures/multiple-sources-with-destination-dir/external/page.html.erb +1 -0
  71. data/fixtures/multiple-sources-with-destination-dir/source/index.html.erb +1 -0
  72. data/fixtures/multiple-sources-with-duplicate-file-names-app/config.rb +1 -1
  73. data/fixtures/multiple-sources-without-destination-dir/config.rb +1 -0
  74. data/fixtures/multiple-sources-without-destination-dir/external/page.html.erb +1 -0
  75. data/fixtures/multiple-sources-without-destination-dir/source/index.html.erb +1 -0
  76. data/fixtures/nested-layout-app/source/another.html.markdown +1 -1
  77. data/fixtures/nested-layout-app/source/haml-test.html.markdown +1 -1
  78. data/fixtures/nested-layout-app/source/slim-test.html.markdown +1 -1
  79. data/fixtures/padrino-helpers-app/config.rb +1 -1
  80. data/fixtures/page-classes-app/config.rb +2 -2
  81. data/fixtures/page-helper-layout-block-app/config.rb +1 -1
  82. data/fixtures/page-id-app/config-proc.rb +4 -4
  83. data/fixtures/page-id-app/config.rb +3 -3
  84. data/fixtures/paginate-app/source/blog/2011-01-01-test-article.html.markdown +1 -1
  85. data/fixtures/paginate-app/source/blog/2011-01-02-test-article.html.markdown +1 -1
  86. data/fixtures/paginate-app/source/blog/2011-01-03-test-article.html.markdown +1 -1
  87. data/fixtures/paginate-app/source/blog/2011-01-04-test-article.html.markdown +1 -1
  88. data/fixtures/paginate-app/source/blog/2011-01-05-test-article.html.markdown +1 -1
  89. data/fixtures/paginate-app/source/blog/2011-02-01-test-article.html.markdown +1 -1
  90. data/fixtures/paginate-app/source/blog/2011-02-02-test-article.html.markdown +1 -1
  91. data/fixtures/partials-app/source/_locals.erb +1 -1
  92. data/fixtures/partials-app/source/locals.html.erb +1 -1
  93. data/fixtures/proxy-pages-app/config.rb +13 -14
  94. data/fixtures/sass-assets-path-app/config.rb +2 -2
  95. data/fixtures/sinatra-app/config.rb +6 -6
  96. data/fixtures/traversal-app/config.rb +4 -4
  97. data/fixtures/v4-extension-callbacks/config.rb +2 -2
  98. data/fixtures/wildcard-app/config.rb +1 -1
  99. data/fixtures/wildcard-directory-index-app/config.rb +1 -1
  100. data/lib/middleman-core.rb +3 -3
  101. data/lib/middleman-core/application.rb +5 -5
  102. data/lib/middleman-core/builder.rb +20 -20
  103. data/lib/middleman-core/callback_manager.rb +1 -1
  104. data/lib/middleman-core/config_context.rb +2 -2
  105. data/lib/middleman-core/configuration.rb +5 -5
  106. data/lib/middleman-core/contracts.rb +2 -2
  107. data/lib/middleman-core/core_extensions/collections.rb +1 -1
  108. data/lib/middleman-core/core_extensions/collections/lazy_root.rb +1 -1
  109. data/lib/middleman-core/core_extensions/collections/lazy_step.rb +9 -9
  110. data/lib/middleman-core/core_extensions/collections/pagination.rb +6 -6
  111. data/lib/middleman-core/core_extensions/data.rb +10 -10
  112. data/lib/middleman-core/core_extensions/default_helpers.rb +26 -22
  113. data/lib/middleman-core/core_extensions/file_watcher.rb +1 -1
  114. data/lib/middleman-core/core_extensions/front_matter.rb +3 -3
  115. data/lib/middleman-core/core_extensions/i18n.rb +24 -24
  116. data/lib/middleman-core/core_extensions/inline_url_rewriter.rb +10 -7
  117. data/lib/middleman-core/core_extensions/routing.rb +1 -1
  118. data/lib/middleman-core/dns_resolver.rb +1 -1
  119. data/lib/middleman-core/dns_resolver/basic_network_resolver.rb +3 -3
  120. data/lib/middleman-core/dns_resolver/hosts_resolver.rb +1 -1
  121. data/lib/middleman-core/dns_resolver/local_link_resolver.rb +1 -1
  122. data/lib/middleman-core/dns_resolver/network_resolver.rb +1 -1
  123. data/lib/middleman-core/extension.rb +26 -25
  124. data/lib/middleman-core/extension_manager.rb +1 -1
  125. data/lib/middleman-core/extensions.rb +8 -7
  126. data/lib/middleman-core/extensions/asset_hash.rb +24 -22
  127. data/lib/middleman-core/extensions/asset_host.rb +10 -10
  128. data/lib/middleman-core/extensions/automatic_alt_tags.rb +1 -1
  129. data/lib/middleman-core/extensions/automatic_image_sizes.rb +3 -3
  130. data/lib/middleman-core/extensions/cache_buster.rb +2 -2
  131. data/lib/middleman-core/extensions/directory_indexes.rb +1 -1
  132. data/lib/middleman-core/extensions/external_pipeline.rb +14 -9
  133. data/lib/middleman-core/extensions/gzip.rb +7 -5
  134. data/lib/middleman-core/extensions/lorem.rb +9 -9
  135. data/lib/middleman-core/extensions/minify_css.rb +9 -9
  136. data/lib/middleman-core/extensions/minify_javascript.rb +10 -10
  137. data/lib/middleman-core/extensions/relative_assets.rb +8 -8
  138. data/lib/middleman-core/file_renderer.rb +6 -5
  139. data/lib/middleman-core/load_paths.rb +10 -10
  140. data/lib/middleman-core/logger.rb +2 -3
  141. data/lib/middleman-core/meta_pages.rb +1 -1
  142. data/lib/middleman-core/preview_server.rb +21 -22
  143. data/lib/middleman-core/preview_server/checks.rb +1 -1
  144. data/lib/middleman-core/preview_server/information.rb +13 -13
  145. data/lib/middleman-core/preview_server/network_interface_inventory.rb +3 -3
  146. data/lib/middleman-core/preview_server/server_information.rb +1 -1
  147. data/lib/middleman-core/preview_server/server_url.rb +1 -1
  148. data/lib/middleman-core/preview_server/tcp_port_prober.rb +1 -1
  149. data/lib/middleman-core/rack.rb +1 -1
  150. data/lib/middleman-core/renderers/coffee_script.rb +2 -2
  151. data/lib/middleman-core/renderers/haml.rb +1 -4
  152. data/lib/middleman-core/renderers/less.rb +1 -1
  153. data/lib/middleman-core/renderers/liquid.rb +2 -1
  154. data/lib/middleman-core/renderers/markdown.rb +7 -7
  155. data/lib/middleman-core/renderers/redcarpet.rb +2 -2
  156. data/lib/middleman-core/renderers/sass.rb +5 -5
  157. data/lib/middleman-core/renderers/sass_functions.rb +5 -5
  158. data/lib/middleman-core/renderers/slim.rb +2 -2
  159. data/lib/middleman-core/sitemap/extensions/ignores.rb +2 -4
  160. data/lib/middleman-core/sitemap/extensions/import.rb +1 -1
  161. data/lib/middleman-core/sitemap/extensions/on_disk.rb +1 -1
  162. data/lib/middleman-core/sitemap/extensions/proxies.rb +2 -1
  163. data/lib/middleman-core/sitemap/extensions/redirects.rb +1 -1
  164. data/lib/middleman-core/sitemap/extensions/request_endpoints.rb +1 -1
  165. data/lib/middleman-core/sitemap/extensions/traversal.rb +80 -25
  166. data/lib/middleman-core/sitemap/resource.rb +21 -20
  167. data/lib/middleman-core/sitemap/store.rb +3 -3
  168. data/lib/middleman-core/sources.rb +12 -12
  169. data/lib/middleman-core/sources/source_watcher.rb +16 -10
  170. data/lib/middleman-core/step_definitions/builder_steps.rb +23 -23
  171. data/lib/middleman-core/step_definitions/commandline_steps.rb +5 -5
  172. data/lib/middleman-core/step_definitions/middleman_steps.rb +13 -14
  173. data/lib/middleman-core/step_definitions/server_steps.rb +14 -16
  174. data/lib/middleman-core/template_context.rb +17 -10
  175. data/lib/middleman-core/template_renderer.rb +34 -32
  176. data/lib/middleman-core/util.rb +2 -2
  177. data/lib/middleman-core/util/binary.rb +3 -1
  178. data/lib/middleman-core/util/data.rb +2 -2
  179. data/lib/middleman-core/util/files.rb +2 -2
  180. data/lib/middleman-core/util/paths.rb +47 -44
  181. data/lib/middleman-core/util/rack.rb +3 -3
  182. data/lib/middleman-core/util/uri_templates.rb +1 -0
  183. data/lib/middleman-core/version.rb +1 -1
  184. data/middleman-core.gemspec +3 -2
  185. data/spec/middleman-core/callbacks_spec.rb +15 -14
  186. data/spec/middleman-core/core_extensions/data_spec.rb +70 -74
  187. data/spec/middleman-core/dns_resolver_spec.rb +6 -6
  188. data/spec/middleman-core/util_spec.rb +81 -86
  189. data/spec/support/given.rb +11 -15
  190. metadata +44 -6
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 52f86ed81089423f830d056b3618e36218d4e478
4
- data.tar.gz: a70572a4e9e68a10ce50860dee7b1bbf012e38d7
2
+ SHA256:
3
+ metadata.gz: 407a6cefc4af923494308fd89533f224e4a41ace633f3047443481148181d5fc
4
+ data.tar.gz: fa06797e795bf36af4fd50b2174f6de794eb11aaa40f1ed39b242852181188ef
5
5
  SHA512:
6
- metadata.gz: f9e6f7ff55b3a7cfb86f966a1ba8c2bdfcbef8481ffcbcfce66d46febd5ad8edd297f813bf1e4e7ccc1b7fd6258a1271752f22180983d9a9ca9d0a2057d0518b
7
- data.tar.gz: e27b12b8c5888a6b5eacd3bf9ae72c7d6b370b09ecc3c71182cf2a4f1f18b1a33347f60b81ee3a17556f7a7a6d8b7ae3ab89de3e14eda4f08ef40b8dac3da071
6
+ metadata.gz: 129679da5f716ac7a5bc64b8928fe0211add698897af3875f57b32f0f89c3bedf0bf11b08f9ba15d7454eb208e7d9cc5c81befd1a71fb624471ac518afb839b4
7
+ data.tar.gz: bedf2d6090c39aa9aa0159d2b31a99b88317fe64252adf6da06222f57f0300b234b87559b5da8a50805d261230ecc8d2b2be7c0dacf7539f2037adc03eb8ea81
data/Rakefile CHANGED
@@ -1,4 +1,3 @@
1
- # coding:utf-8
2
1
  RAKE_ROOT = __FILE__.freeze
3
2
  GEM_NAME = ENV['NAME'] || 'middleman-core'
4
3
  require File.expand_path(File.dirname(__FILE__) + '/../gem_rake_helper')
data/cucumber.yml CHANGED
@@ -1,2 +1,2 @@
1
- default: --require features --tags ~@wip
2
- wip: --require features --tags @wip
1
+ default: --fail-fast --require features --tags 'not @wip'
2
+ wip: --fail-fast --require features --tags @wip
@@ -179,14 +179,14 @@ Feature: Assets get file hashes appended to them and references to them are upda
179
179
  font-size: 14px
180
180
  """
181
181
  When I go to "/partials/"
182
- Then I should see 'href="../stylesheets/uses_partials-58447acf.css'
182
+ Then I should see 'href="../stylesheets/uses_partials-a3c8302b.css'
183
183
  And the file "source/stylesheets/_partial.sass" has the contents
184
184
  """
185
185
  body
186
186
  font-size: 18px !important
187
187
  """
188
188
  When I go to "/partials/"
189
- Then I should see 'href="../stylesheets/uses_partials-72fbbb45.css'
189
+ Then I should see 'href="../stylesheets/uses_partials-08ee47a7.css'
190
190
 
191
191
  Scenario: The asset hash should change when a Rack-based filter changes
192
192
  Given a fixture app "asset-hash-app"
@@ -111,7 +111,7 @@ Feature: Collections
111
111
  """
112
112
  ---
113
113
  title: "Blog3 Another Article"
114
- date: 2011-01-02
114
+ date: "2011-01-02"
115
115
  tags:
116
116
  - foo
117
117
  ---
@@ -133,7 +133,7 @@ Feature: Collections
133
133
  """
134
134
  ---
135
135
  title: "Blog2 Yet Another Article"
136
- date: 2011-01-02
136
+ date: "2011-01-02"
137
137
  tags:
138
138
  - foo
139
139
  ---
@@ -37,3 +37,11 @@ Feature: i18n merging path trees
37
37
  When I go to "/es/b/sub.html"
38
38
  Then I should see "Current locale: es"
39
39
  Then I should see "path: is-localized Home # b/index.html.erb # b/sub.html.erb"
40
+
41
+ When I go to "/c/d/index.html"
42
+ Then I should see "Current locale: en"
43
+ Then I should see "path: is-localized Home # c/d/index.html.erb"
44
+
45
+ When I go to "/es/c/d/index.html"
46
+ Then I should see "Current locale: es"
47
+ Then I should see "path: is-localized Home # c/d/index.html.erb"
@@ -6,7 +6,6 @@ Feature: Markdown support
6
6
  When I go to "/index.html"
7
7
  Then I should see "<p>Hello World</p>"
8
8
 
9
- @encoding
10
9
  Scenario: Markdown extensions (Maruku)
11
10
  Given the Server is running at "markdown-app"
12
11
  When I go to "/smarty_pants.html"
@@ -0,0 +1,40 @@
1
+ Feature: Allow content with multiple sources to reload
2
+ Scenario: With source that does not specify a destination directory
3
+ Given the Server is running at "multiple-sources-without-destination-dir"
4
+ When I go to "/page.html"
5
+ Then I should see "Before edit"
6
+
7
+ When the file "external/page.html.erb" has the contents
8
+ """
9
+ After edit
10
+ """
11
+ And I go to "/page.html"
12
+ Then I should see "After edit"
13
+
14
+
15
+ Scenario: With source that specifies destination directory
16
+ Given the Server is running at "multiple-sources-with-destination-dir"
17
+ When I go to "/external/page.html"
18
+ Then I should see "Before edit"
19
+
20
+ When the file "external/page.html.erb" has the contents
21
+ """
22
+ After edit
23
+ """
24
+ And I go to "/external/page.html"
25
+ Then I should see "After edit"
26
+
27
+ Scenario: With external source and a destination directory name different from source directory name
28
+ Given a fixture app "destination-dir-different-from-source-dir-name"
29
+ And I cd to "my-app"
30
+ And the Server is running
31
+
32
+ When I go to "/my_dir/page.html"
33
+ Then I should see "Before edit"
34
+
35
+ When the file "../external/page.html.erb" has the contents
36
+ """
37
+ After edit
38
+ """
39
+ And I go to "/my_dir/page.html"
40
+ Then I should see "After edit"
@@ -37,7 +37,7 @@ Feature: Provide Sane Defaults for Partial Behavior
37
37
  Scenario: Partials can be passed locals
38
38
  Given the Server is running at "partials-app"
39
39
  When I go to "/locals.html"
40
- Then I should see "Local var is bar"
40
+ Then I should see "Local vars are 'foo', 'bar' and 'baz'"
41
41
 
42
42
  Scenario: Partial and Layout use different engines
43
43
  Given the Server is running at "different-engine-partial"
@@ -1,5 +1,6 @@
1
- ENV["TEST"] = "true"
1
+ ENV['TEST'] = 'true'
2
2
 
3
+ require 'backports/latest'
3
4
  require 'sassc'
4
5
 
5
6
  require 'simplecov'
@@ -8,6 +9,8 @@ SimpleCov.root(File.expand_path(File.dirname(__FILE__) + '/../..'))
8
9
  require 'phantomjs/poltergeist'
9
10
  Capybara.javascript_driver = :poltergeist
10
11
 
12
+ Capybara.server = :webrick
13
+
11
14
  require 'simplecov'
12
15
  SimpleCov.start
13
16
 
@@ -1,5 +1,3 @@
1
- @encoding
2
-
3
1
  Feature: Tilde directories
4
2
  In order to support ~ characters in directories
5
3
 
@@ -1,4 +1,4 @@
1
- @encoding @travishatesme @wip
1
+ @wip
2
2
 
3
3
  Feature: Unicode filenames
4
4
  In order to support non-ASCII characters in filenames
@@ -1,4 +1,3 @@
1
-
2
1
  activate :asset_hash
3
2
 
4
3
  activate :relative_assets
@@ -6,8 +6,8 @@ class Middleware
6
6
  def call(env)
7
7
  status, headers, response = @app.call(env)
8
8
  body = ''
9
- response.each {|part| body += part }
10
- if (env["PATH_INFO"] =~ /css$/)
9
+ response.each { |part| body += part }
10
+ if /css$/.match?(env['PATH_INFO'])
11
11
  body += "\n/* Added by Rack filter */"
12
12
  status, headers, response = Rack::Response.new(body, status, headers).finish
13
13
  end
@@ -1,2 +1,2 @@
1
1
  body
2
- font-size: 18px
2
+ font-size: 18px
@@ -1,6 +1,5 @@
1
-
2
1
  activate :asset_hash,
3
- prefix: "myprefix-"
2
+ prefix: 'myprefix-'
4
3
 
5
4
  activate :relative_assets
6
5
 
@@ -6,8 +6,8 @@ class Middleware
6
6
  def call(env)
7
7
  status, headers, response = @app.call(env)
8
8
  body = ''
9
- response.each {|part| body += part }
10
- if (env["PATH_INFO"] =~ /css$/)
9
+ response.each { |part| body += part }
10
+ if /css$/.match?(env['PATH_INFO'])
11
11
  body += "\n/* Added by Rack filter */"
12
12
  status, headers, response = Rack::Response.new(body, status, headers).finish
13
13
  end
@@ -1,4 +1,3 @@
1
-
2
1
  activate :asset_hash
3
2
 
4
3
  activate :relative_assets
@@ -6,8 +6,8 @@ class Middleware
6
6
  def call(env)
7
7
  status, headers, response = @app.call(env)
8
8
  body = ''
9
- response.each {|part| body += part }
10
- if (env["PATH_INFO"] =~ /css$/)
9
+ response.each { |part| body += part }
10
+ if /css$/.match?(env['PATH_INFO'])
11
11
  body += "\n/* Added by Rack filter */"
12
12
  status, headers, response = Rack::Response.new(body, status, headers).finish
13
13
  end
@@ -1 +1 @@
1
- activate :asset_host, host: "http://assets1.example.com"
1
+ activate :asset_host, host: 'http://assets1.example.com'
@@ -1,9 +1,9 @@
1
- %w{
1
+ %w[
2
2
  /auto-css.html
3
3
  /auto-css
4
4
  /auto-css/
5
5
  /auto-css/auto-css.html
6
6
  /auto-css/sub/auto-css.html
7
- }.each do |path|
7
+ ].each do |path|
8
8
  page path, layout: false
9
9
  end
@@ -1,9 +1,9 @@
1
- %w{
1
+ %w[
2
2
  /auto-js.html
3
3
  /auto-js
4
4
  /auto-js/
5
5
  /auto-js/auto-js.html
6
6
  /auto-js/sub/auto-js.html
7
- }.each do |path|
7
+ ].each do |path|
8
8
  page path, layout: false
9
9
  end
@@ -1 +1 @@
1
- activate :directory_indexes
1
+ activate :directory_indexes
@@ -1 +1 @@
1
- set :automatic_directory_matcher, "--"
1
+ set :automatic_directory_matcher, '--'
@@ -1,2 +1,2 @@
1
- page "/data.html", layout: false
2
- page "/data3.html", layout: false
1
+ page '/data.html', layout: false
2
+ page '/data3.html', layout: false
@@ -1,5 +1,5 @@
1
- require "slim"
1
+ require 'slim'
2
2
 
3
- page "/capture_html_erb.html", layout: :capture_html
4
- page "/capture_html_haml.html", layout: :capture_html
5
- page "/capture_html_slim.html", layout: :capture_html
3
+ page '/capture_html_erb.html', layout: :capture_html
4
+ page '/capture_html_haml.html', layout: :capture_html
5
+ page '/capture_html_slim.html', layout: :capture_html
@@ -1,9 +1,9 @@
1
- proxy "/fake.html", "/real.html", layout: false
1
+ proxy '/fake.html', '/real.html', layout: false
2
2
 
3
- ignore "/should_be_ignored.html"
4
- ignore "/should_be_ignored2.html"
5
- proxy "/target_ignore.html", "/should_be_ignored3.html", ignore: true
3
+ ignore '/should_be_ignored.html'
4
+ ignore '/should_be_ignored2.html'
5
+ proxy '/target_ignore.html', '/should_be_ignored3.html', ignore: true
6
6
 
7
- %w(one two).each do |num|
8
- proxy "/fake/#{num}.html", "/real/index.html", locals: { num: num }
7
+ %w[one two].each do |num|
8
+ proxy "/fake/#{num}.html", '/real/index.html', locals: { num: num }
9
9
  end
@@ -1,5 +1,5 @@
1
- set :build_dir, ".build"
1
+ set :build_dir, '.build'
2
2
 
3
- ignore "/should_be_ignored.html"
4
- ignore "/should_be_ignored2.html"
5
- proxy "/target_ignore.html", "/should_be_ignored3.html", ignore: true
3
+ ignore '/should_be_ignored.html'
4
+ ignore '/should_be_ignored2.html'
5
+ proxy '/target_ignore.html', '/should_be_ignored3.html', ignore: true
@@ -1 +1 @@
1
- set :build_dir, ".build"
1
+ set :build_dir, '.build'
@@ -1,9 +1,9 @@
1
- proxy "/fake.html", "/real.html", layout: false
1
+ proxy '/fake.html', '/real.html', layout: false
2
2
 
3
- ignore "/should_be_ignored.html"
4
- ignore "/should_be_ignored2.html"
5
- proxy "/target_ignore.html", "/should_be_ignored3.html", ignore: true
3
+ ignore '/should_be_ignored.html'
4
+ ignore '/should_be_ignored2.html'
5
+ proxy '/target_ignore.html', '/should_be_ignored3.html', ignore: true
6
6
 
7
- %w(one two).each do |num|
8
- proxy "/fake/#{num}.html", "/real/index.html", locals: { num: num }
7
+ %w[one two].each do |num|
8
+ proxy "/fake/#{num}.html", '/real/index.html', locals: { num: num }
9
9
  end
@@ -1,2 +1 @@
1
1
  activate :directory_indexes
2
-
@@ -1 +1 @@
1
- set :build_dir, "sub/dir"
1
+ set :build_dir, 'sub/dir'
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  title: "Blog1 Newer Article"
3
- date: 2011-01-01
3
+ date: "2011-01-01"
4
4
  tags: foo, bar
5
5
  ---
6
6
 
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  title: "Blog1 Another Article"
3
- date: 2011-01-02
3
+ date: "2011-01-02"
4
4
  tags:
5
5
  - foo
6
6
  - 120
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  title: "Blog2 Newer Article"
3
- date: 2011-01-01
3
+ date: "2011-01-01"
4
4
  tags: foo, bar
5
5
  ---
6
6
 
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  title: "Blog2 Another Article"
3
- date: 2011-01-02
3
+ date: "2011-01-02"
4
4
  tags:
5
5
  - foo
6
6
  ---
@@ -1,5 +1,5 @@
1
- require "slim"
1
+ require 'slim'
2
2
 
3
- page "/content_for_erb.html", layout: :content_for
4
- page "/content_for_haml.html", layout: :content_for
5
- page "/content_for_slim.html", layout: :content_for
3
+ page '/content_for_erb.html', layout: :content_for
4
+ page '/content_for_haml.html', layout: :content_for
5
+ page '/content_for_slim.html', layout: :content_for
@@ -0,0 +1,2 @@
1
+ files.watch :source, path: File.join(root, '..', 'external'),
2
+ destination_dir: 'my_dir'
@@ -1,34 +1,33 @@
1
- # -*- coding: utf-8 -*-
2
- proxy "/fake.html", "/real.html", layout: false
3
- proxy "fake2.html", "/real.html", layout: false
4
- proxy "fake3.html", "real.html", layout: false
5
- proxy "/fake4.html", "real.html", layout: false
1
+ proxy '/fake.html', '/real.html', layout: false
2
+ proxy 'fake2.html', '/real.html', layout: false
3
+ proxy 'fake3.html', 'real.html', layout: false
4
+ proxy '/fake4.html', 'real.html', layout: false
6
5
 
7
- ignore "/should_be_ignored.html"
8
- ignore "/should_be_ignored2.html"
9
- proxy "/target_ignore.html", "/should_be_ignored3.html", ignore: true
6
+ ignore '/should_be_ignored.html'
7
+ ignore '/should_be_ignored2.html'
8
+ proxy '/target_ignore.html', '/should_be_ignored3.html', ignore: true
10
9
 
11
- ignore "should_be_ignored4.html"
12
- ignore "should_be_ignored5.html"
13
- proxy "target_ignore2.html", "/should_be_ignored6.html", ignore: true
14
- proxy "target_ignore3.html", "should_be_ignored7.html", ignore: true
15
- proxy "/target_ignore4.html", "should_be_ignored8.html", ignore: true
10
+ ignore 'should_be_ignored4.html'
11
+ ignore 'should_be_ignored5.html'
12
+ proxy 'target_ignore2.html', '/should_be_ignored6.html', ignore: true
13
+ proxy 'target_ignore3.html', 'should_be_ignored7.html', ignore: true
14
+ proxy '/target_ignore4.html', 'should_be_ignored8.html', ignore: true
16
15
 
17
- %w(one two).each do |num|
18
- proxy "/fake/#{num}.html", "/real/index.html", ignore: true, locals: { num: num }
19
- proxy "fake2/#{num}.html", "/real/index.html", ignore: true, locals: { num: num }
20
- proxy "fake3/#{num}.html", "real/index.html", ignore: true, locals: { num: num }
21
- proxy "/fake4/#{num}.html", "real/index.html", ignore: true, locals: { num: num }
16
+ %w[one two].each do |num|
17
+ proxy "/fake/#{num}.html", '/real/index.html', ignore: true, locals: { num: num }
18
+ proxy "fake2/#{num}.html", '/real/index.html', ignore: true, locals: { num: num }
19
+ proxy "fake3/#{num}.html", 'real/index.html', ignore: true, locals: { num: num }
20
+ proxy "/fake4/#{num}.html", 'real/index.html', ignore: true, locals: { num: num }
22
21
  end
23
22
 
24
- proxy "明日がある.html", "/real.html", layout: false
23
+ proxy '明日がある.html', '/real.html', layout: false
25
24
 
26
- page "f*/*", locals: { all_glob: "I am all glob" }
27
- page "fake/*", locals: { glob_var: "I am one glob" }
28
- page "fake2/*", locals: { glob_var: "I am two glob" }
29
- page "fake3/*", locals: { glob_var: "I am three glob" }
30
- page "fake4/*", locals: { glob_var: "I am four glob" }
25
+ page 'f*/*', locals: { all_glob: 'I am all glob' }
26
+ page 'fake/*', locals: { glob_var: 'I am one glob' }
27
+ page 'fake2/*', locals: { glob_var: 'I am two glob' }
28
+ page 'fake3/*', locals: { glob_var: 'I am three glob' }
29
+ page 'fake4/*', locals: { glob_var: 'I am four glob' }
31
30
 
32
- ["tom", "dick", "harry"].each do |name|
33
- proxy "/about/#{name}.html", "/should_be_ignored9.html", locals: { person_name: name }, ignore: true
31
+ %w[tom dick harry].each do |name|
32
+ proxy "/about/#{name}.html", '/should_be_ignored9.html', locals: { person_name: name }, ignore: true
34
33
  end