henshin 0.0.0 → 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (152) hide show
  1. data/.yardoc/checksums +1 -3
  2. data/.yardoc/objects/Hash.dat +0 -0
  3. data/.yardoc/objects/Hash/to_options_i.dat +0 -0
  4. data/.yardoc/objects/Henshin.dat +0 -0
  5. data/.yardoc/objects/Henshin/CSSGenerator.dat +0 -0
  6. data/.yardoc/objects/Henshin/CSSGenerator/generate_i.dat +0 -0
  7. data/.yardoc/objects/Henshin/Defaults.dat +0 -0
  8. data/.yardoc/objects/Henshin/Gen.dat +0 -0
  9. data/.yardoc/objects/Henshin/Gen/config_3D_i.dat +0 -0
  10. data/.yardoc/objects/Henshin/Gen/config_i.dat +0 -0
  11. data/.yardoc/objects/Henshin/Gen/content_3D_i.dat +0 -0
  12. data/.yardoc/objects/Henshin/Gen/content_i.dat +0 -0
  13. data/.yardoc/objects/Henshin/Gen/date_3D_i.dat +0 -0
  14. data/.yardoc/objects/Henshin/Gen/date_i.dat +0 -0
  15. data/.yardoc/objects/Henshin/Gen/extension_3D_i.dat +0 -0
  16. data/.yardoc/objects/Henshin/Gen/extension_i.dat +0 -0
  17. data/.yardoc/objects/Henshin/Gen/initialize_i.dat +0 -0
  18. data/.yardoc/objects/Henshin/Gen/layout_3D_i.dat +0 -0
  19. data/.yardoc/objects/Henshin/Gen/layout_i.dat +0 -0
  20. data/.yardoc/objects/Henshin/Gen/override_i.dat +0 -0
  21. data/.yardoc/objects/Henshin/Gen/path_3D_i.dat +0 -0
  22. data/.yardoc/objects/Henshin/Gen/path_i.dat +0 -0
  23. data/.yardoc/objects/Henshin/Gen/payload_i.dat +0 -0
  24. data/.yardoc/objects/Henshin/Gen/process_i.dat +0 -0
  25. data/.yardoc/objects/Henshin/Gen/read_yaml_i.dat +0 -0
  26. data/.yardoc/objects/Henshin/Gen/render_i.dat +0 -0
  27. data/.yardoc/objects/Henshin/Gen/site_3D_i.dat +0 -0
  28. data/.yardoc/objects/Henshin/Gen/site_i.dat +0 -0
  29. data/.yardoc/objects/Henshin/Gen/title_3D_i.dat +0 -0
  30. data/.yardoc/objects/Henshin/Gen/title_i.dat +0 -0
  31. data/.yardoc/objects/Henshin/Gen/write_i.dat +0 -0
  32. data/.yardoc/objects/Henshin/HTMLGenerator.dat +0 -0
  33. data/.yardoc/objects/Henshin/HTMLGenerator/generate_i.dat +0 -0
  34. data/.yardoc/objects/Henshin/JSGenerator.dat +0 -0
  35. data/.yardoc/objects/Henshin/JSGenerator/generate_i.dat +0 -0
  36. data/.yardoc/objects/Henshin/LayoutParser.dat +0 -0
  37. data/.yardoc/objects/Henshin/LayoutParser/generate_i.dat +0 -0
  38. data/.yardoc/objects/Henshin/Post.dat +0 -0
  39. data/.yardoc/objects/Henshin/Post/author_3D_i.dat +0 -0
  40. data/.yardoc/objects/Henshin/Post/author_i.dat +0 -0
  41. data/.yardoc/objects/Henshin/Post/category_3D_i.dat +0 -0
  42. data/.yardoc/objects/Henshin/Post/category_i.dat +0 -0
  43. data/.yardoc/objects/Henshin/Post/date_3D_i.dat +0 -0
  44. data/.yardoc/objects/Henshin/Post/date_i.dat +0 -0
  45. data/.yardoc/objects/Henshin/Post/initialize_i.dat +0 -0
  46. data/.yardoc/objects/Henshin/Post/override_i.dat +0 -0
  47. data/.yardoc/objects/Henshin/Post/payload_i.dat +0 -0
  48. data/.yardoc/objects/Henshin/Post/permalink_i.dat +0 -0
  49. data/.yardoc/objects/Henshin/Post/process_i.dat +0 -0
  50. data/.yardoc/objects/Henshin/Post/read_name_i.dat +0 -0
  51. data/.yardoc/objects/Henshin/Post/read_yaml_i.dat +0 -0
  52. data/.yardoc/objects/Henshin/Post/tags_3D_i.dat +0 -0
  53. data/.yardoc/objects/Henshin/Post/tags_i.dat +0 -0
  54. data/.yardoc/objects/Henshin/Post/title_3D_i.dat +0 -0
  55. data/.yardoc/objects/Henshin/Post/title_i.dat +0 -0
  56. data/.yardoc/objects/Henshin/Post/write_i.dat +0 -0
  57. data/.yardoc/objects/Henshin/Site.dat +0 -0
  58. data/.yardoc/objects/Henshin/Site/archives_3D_i.dat +0 -0
  59. data/.yardoc/objects/Henshin/Site/archives_i.dat +0 -0
  60. data/.yardoc/objects/Henshin/Site/categories_3D_i.dat +0 -0
  61. data/.yardoc/objects/Henshin/Site/categories_i.dat +0 -0
  62. data/.yardoc/objects/Henshin/Site/config_3D_i.dat +0 -0
  63. data/.yardoc/objects/Henshin/Site/config_i.dat +0 -0
  64. data/.yardoc/objects/Henshin/Site/gens_3D_i.dat +0 -0
  65. data/.yardoc/objects/Henshin/Site/gens_i.dat +0 -0
  66. data/.yardoc/objects/Henshin/Site/initialize_i.dat +0 -0
  67. data/.yardoc/objects/Henshin/Site/layouts_3D_i.dat +0 -0
  68. data/.yardoc/objects/Henshin/Site/layouts_i.dat +0 -0
  69. data/.yardoc/objects/Henshin/Site/payload_i.dat +0 -0
  70. data/.yardoc/objects/Henshin/Site/plugins_3D_i.dat +0 -0
  71. data/.yardoc/objects/Henshin/Site/plugins_i.dat +0 -0
  72. data/.yardoc/objects/Henshin/Site/posts_3D_i.dat +0 -0
  73. data/.yardoc/objects/Henshin/Site/posts_i.dat +0 -0
  74. data/.yardoc/objects/Henshin/Site/process_i.dat +0 -0
  75. data/.yardoc/objects/Henshin/Site/read_i.dat +0 -0
  76. data/.yardoc/objects/Henshin/Site/read_layouts_i.dat +0 -0
  77. data/.yardoc/objects/Henshin/Site/read_others_i.dat +0 -0
  78. data/.yardoc/objects/Henshin/Site/read_posts_i.dat +0 -0
  79. data/.yardoc/objects/Henshin/Site/render_i.dat +0 -0
  80. data/.yardoc/objects/Henshin/Site/reset_i.dat +0 -0
  81. data/.yardoc/objects/Henshin/Site/statics_3D_i.dat +0 -0
  82. data/.yardoc/objects/Henshin/Site/statics_i.dat +0 -0
  83. data/.yardoc/objects/Henshin/Site/tags_3D_i.dat +0 -0
  84. data/.yardoc/objects/Henshin/Site/tags_i.dat +0 -0
  85. data/.yardoc/objects/Henshin/Site/write_i.dat +0 -0
  86. data/.yardoc/objects/Henshin/StandardPlugin.dat +0 -0
  87. data/.yardoc/objects/Henshin/configure_c.dat +0 -0
  88. data/.yardoc/objects/Henshin/extensions_c.dat +0 -0
  89. data/.yardoc/objects/Henshin/load_plugins_c.dat +0 -0
  90. data/.yardoc/objects/LiquidPlugin.dat +0 -0
  91. data/.yardoc/objects/LiquidPlugin/extensions_3D_i.dat +0 -0
  92. data/.yardoc/objects/LiquidPlugin/extensions_i.dat +0 -0
  93. data/.yardoc/objects/LiquidPlugin/generate_i.dat +0 -0
  94. data/.yardoc/objects/LiquidPlugin/initialize_i.dat +0 -0
  95. data/.yardoc/objects/LiquidPlugin/read_i.dat +0 -0
  96. data/.yardoc/objects/MarukuPlugin.dat +0 -0
  97. data/.yardoc/objects/MarukuPlugin/extensions_3D_i.dat +0 -0
  98. data/.yardoc/objects/MarukuPlugin/extensions_i.dat +0 -0
  99. data/.yardoc/objects/MarukuPlugin/generate_i.dat +0 -0
  100. data/.yardoc/objects/MarukuPlugin/initialize_i.dat +0 -0
  101. data/.yardoc/objects/PygmentsPlugin.dat +0 -0
  102. data/.yardoc/objects/PygmentsPlugin/extensions_3D_i.dat +0 -0
  103. data/.yardoc/objects/PygmentsPlugin/extensions_i.dat +0 -0
  104. data/.yardoc/objects/PygmentsPlugin/generate_i.dat +0 -0
  105. data/.yardoc/objects/PygmentsPlugin/initialize_i.dat +0 -0
  106. data/.yardoc/objects/SassPlugin.dat +0 -0
  107. data/.yardoc/objects/SassPlugin/extensions_3D_i.dat +0 -0
  108. data/.yardoc/objects/SassPlugin/extensions_i.dat +0 -0
  109. data/.yardoc/objects/SassPlugin/generate_i.dat +0 -0
  110. data/.yardoc/objects/SassPlugin/initialize_i.dat +0 -0
  111. data/.yardoc/objects/String.dat +0 -0
  112. data/.yardoc/objects/String/directory_i.dat +0 -0
  113. data/.yardoc/objects/String/extension_i.dat +0 -0
  114. data/.yardoc/objects/String/file_name_i.dat +0 -0
  115. data/.yardoc/objects/String/slugify_i.dat +0 -0
  116. data/VERSION +1 -1
  117. data/doc/Hash.html +1 -1
  118. data/doc/Henshin.html +2 -2
  119. data/doc/Henshin/CSSGenerator.html +1 -1
  120. data/doc/Henshin/Gen.html +1 -1
  121. data/doc/Henshin/HTMLGenerator.html +1 -1
  122. data/doc/Henshin/JSGenerator.html +1 -1
  123. data/doc/Henshin/LayoutParser.html +1 -1
  124. data/doc/Henshin/Post.html +1 -1
  125. data/doc/Henshin/Site.html +1 -1
  126. data/doc/Henshin/StandardPlugin.html +1 -1
  127. data/doc/LiquidPlugin.html +1 -1
  128. data/doc/MarukuPlugin.html +1 -1
  129. data/doc/PygmentsPlugin.html +1 -1
  130. data/doc/SassPlugin.html +1 -1
  131. data/doc/String.html +1 -1
  132. data/doc/_index.html +1 -1
  133. data/doc/file.README.html +3 -1
  134. data/doc/index.html +3 -1
  135. data/doc/method_list.html +52 -52
  136. data/doc/top-level-namespace.html +1 -1
  137. data/henshin.gemspec +10 -4
  138. data/lib/henshin.rb +1 -1
  139. data/lib/henshin/gen.rb +27 -9
  140. data/lib/henshin/plugins/maruku.rb +5 -2
  141. data/lib/henshin/plugins/sass.rb +13 -4
  142. data/lib/henshin/site.rb +15 -8
  143. data/lib/henshin/static.rb +26 -0
  144. data/test/site/_site/css/print.css +33 -0
  145. data/test/site/_site/css/screen.css +15 -0
  146. data/test/site/_site/index.html +1 -25
  147. data/test/site/_site/static.html +19 -0
  148. data/test/site/css/screen.css +15 -0
  149. data/test/site/sass/print.sass +37 -0
  150. data/test/site/static.html +19 -0
  151. metadata +10 -4
  152. data/.document +0 -5
@@ -0,0 +1,26 @@
1
+ module Henshin
2
+
3
+ class Static
4
+
5
+ attr_accessor :path, :site, :config, :content
6
+
7
+ def initialize( path, site )
8
+ @path = path
9
+ @site = site
10
+ @config = site.config
11
+ @content = File.read( path )
12
+ end
13
+
14
+ ##
15
+ # Writes the file to the correct place
16
+ def write
17
+ write_path = File.join( config[:root], config[:target], @path[ config[:root].size..-1 ] )
18
+
19
+ FileUtils.mkdir_p File.join( write_path.directory )
20
+ file = File.new( File.join( write_path ), "w" )
21
+ file.puts( @content )
22
+ end
23
+
24
+ end
25
+
26
+ end
@@ -0,0 +1,33 @@
1
+ body, div, dl, dt, dd, ul, ol, li, h1, h2, h3, h4, h5, h6, pre, form, fieldset, input, textarea, p, blockquote, th, td {
2
+ margin: 0;
3
+ padding: 0; }
4
+
5
+ table {
6
+ border-collapse: collapse;
7
+ border-spacing: 0; }
8
+
9
+ fieldset, img {
10
+ border: 0; }
11
+
12
+ address, caption, cite, code, dfn, em, strong, th, var {
13
+ font-style: normal;
14
+ font-weight: normal; }
15
+
16
+ ol, ul {
17
+ list-style: none; }
18
+
19
+ caption, th {
20
+ text-align: left; }
21
+
22
+ h1, h2, h3, h4, h5, h6 {
23
+ font-size: 100%;
24
+ font-weight: normal; }
25
+
26
+ q:before, q:after {
27
+ content: ”; }
28
+
29
+ abbr, acronym {
30
+ border: 0; }
31
+
32
+ h1 {
33
+ font-size: 2em; }
@@ -0,0 +1,15 @@
1
+ /* Testing whether static files, eg this, are correctly copied and ignored */
2
+
3
+ body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,form,fieldset,input,textarea,p,
4
+ blockquote,th,td {margin:0; padding:0; }
5
+ table { border-collapse:collapse; border-spacing:0; }
6
+ fieldset,img { border:0; }
7
+ address,caption,cite,code,dfn,em,strong,th,var { font-style:normal; font-weight:normal; }
8
+ ol,ul { list-style:none; }
9
+ caption,th { text-align:left; }
10
+ h1,h2,h3,h4,h5,h6 { font-size:100%; font-weight:normal; }
11
+ q:before,q:after { content:”; }
12
+ abbr,acronym { border:0; }
13
+ html {font-size: 62.5%;}p {font-size: 1.2em;}
14
+ h1 {font-size: 2em;}
15
+ a:hover, a:active { outline: none; }
@@ -1,29 +1,5 @@
1
- <!DOCTYPE html>
2
- <html lang="en">
3
- <head>
4
- <meta charset="utf-8" />
5
- <title></title>
6
- <link rel="stylesheet" href="" type="text/css" />
7
- </head>
8
- <body>
9
-
10
- <header>
11
- <h1></h1>
12
- <time></time>
13
- <ul>
14
- <li>tags</li>
15
- <li>should</li>
16
- <li>be loopable</li>
17
- </ul>
18
- </header>
19
-
20
- <header>
1
+ <header>
21
2
  <h1>Joshua Hawxwell</h1>
22
3
  </header>
23
4
 
24
5
  <p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>
25
-
26
-
27
- <span>Copyright &copy; </span>
28
- </body>
29
- </html>
@@ -0,0 +1,19 @@
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8" />
5
+ <title></title>
6
+ <link rel="stylesheet" href="" type="text/css" />
7
+ </head>
8
+ <body>
9
+
10
+
11
+ <header>
12
+ <h1>This should just be copied over</h1>
13
+ </header>
14
+
15
+ <p>I should be in the root folder! No templates or anything</p>
16
+
17
+
18
+ </body>
19
+ </html>
@@ -0,0 +1,15 @@
1
+ /* Testing whether static files, eg this, are correctly copied and ignored */
2
+
3
+ body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,form,fieldset,input,textarea,p,
4
+ blockquote,th,td {margin:0; padding:0; }
5
+ table { border-collapse:collapse; border-spacing:0; }
6
+ fieldset,img { border:0; }
7
+ address,caption,cite,code,dfn,em,strong,th,var { font-style:normal; font-weight:normal; }
8
+ ol,ul { list-style:none; }
9
+ caption,th { text-align:left; }
10
+ h1,h2,h3,h4,h5,h6 { font-size:100%; font-weight:normal; }
11
+ q:before,q:after { content:”; }
12
+ abbr,acronym { border:0; }
13
+ html {font-size: 62.5%;}p {font-size: 1.2em;}
14
+ h1 {font-size: 2em;}
15
+ a:hover, a:active { outline: none; }
@@ -0,0 +1,37 @@
1
+ // This is to test whether sass files are successfully created
2
+ // and placed in the css folder (or whatever is defined
3
+
4
+ body, div, dl, dt, dd, ul, ol, li, h1, h2, h3, h4, h5, h6, pre, form, fieldset, input, textarea, p, blockquote, th, td
5
+ margin: 0
6
+ padding: 0
7
+
8
+ table
9
+ border-collapse: collapse
10
+ border-spacing: 0
11
+
12
+ fieldset, img
13
+ border: 0
14
+
15
+ address, caption, cite, code, dfn, em, strong, th, var
16
+ font-style: normal
17
+ font-weight: normal
18
+
19
+ ol, ul
20
+ list-style: none
21
+
22
+ caption, th
23
+ text-align: left
24
+
25
+ h1, h2, h3, h4, h5, h6
26
+ font-size: 100%
27
+ font-weight: normal
28
+
29
+ q
30
+ &:before, &:after
31
+ content: ”
32
+
33
+ abbr, acronym
34
+ border: 0
35
+
36
+ h1
37
+ font-size: 2em
@@ -0,0 +1,19 @@
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8" />
5
+ <title></title>
6
+ <link rel="stylesheet" href="" type="text/css" />
7
+ </head>
8
+ <body>
9
+
10
+
11
+ <header>
12
+ <h1>This should just be copied over</h1>
13
+ </header>
14
+
15
+ <p>I should be in the root folder! No templates or anything</p>
16
+
17
+
18
+ </body>
19
+ </html>
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 0
8
- - 0
9
- version: 0.0.0
8
+ - 1
9
+ version: 0.0.1
10
10
  platform: ruby
11
11
  authors:
12
12
  - hawx
@@ -14,7 +14,7 @@ autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
16
 
17
- date: 2010-05-19 00:00:00 +01:00
17
+ date: 2010-05-20 00:00:00 +01:00
18
18
  default_executable: henshin
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency
@@ -51,7 +51,6 @@ extra_rdoc_files:
51
51
  - LICENSE
52
52
  - README.markdown
53
53
  files:
54
- - .document
55
54
  - .gitignore
56
55
  - .yardoc/checksums
57
56
  - .yardoc/objects/Hash.dat
@@ -215,16 +214,23 @@ files:
215
214
  - lib/henshin/plugins/sass.rb
216
215
  - lib/henshin/post.rb
217
216
  - lib/henshin/site.rb
217
+ - lib/henshin/static.rb
218
218
  - test/helper.rb
219
219
  - test/site/_site/2010/10/20-testing-stuff/index.html
220
220
  - test/site/_site/2010/5/15-lorem-ipsum/index.html
221
+ - test/site/_site/css/print.css
222
+ - test/site/_site/css/screen.css
221
223
  - test/site/_site/index.html
224
+ - test/site/_site/static.html
225
+ - test/site/css/screen.css
222
226
  - test/site/index.html
223
227
  - test/site/layouts/main.html
224
228
  - test/site/layouts/post.html
225
229
  - test/site/options.yaml
226
230
  - test/site/posts/Testing-Stuff.markdown
227
231
  - test/site/posts/lorem-ipsum.markdown
232
+ - test/site/sass/print.sass
233
+ - test/site/static.html
228
234
  - test/test_henshin.rb
229
235
  has_rdoc: true
230
236
  homepage: http://github.com/hawx/henshin
data/.document DELETED
@@ -1,5 +0,0 @@
1
- README.rdoc
2
- lib/**/*.rb
3
- bin/*
4
- features/**/*.feature
5
- LICENSE