mattmatt-jekyll 0.4.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (48) hide show
  1. data/History.txt +91 -0
  2. data/README.textile +494 -0
  3. data/Rakefile +76 -0
  4. data/TODO +3 -0
  5. data/VERSION.yml +4 -0
  6. data/bin/jekyll +142 -0
  7. data/lib/jekyll.rb +64 -0
  8. data/lib/jekyll/albino.rb +116 -0
  9. data/lib/jekyll/converters/csv.rb +26 -0
  10. data/lib/jekyll/converters/mephisto.rb +79 -0
  11. data/lib/jekyll/converters/mt.rb +59 -0
  12. data/lib/jekyll/converters/textpattern.rb +50 -0
  13. data/lib/jekyll/converters/typo.rb +49 -0
  14. data/lib/jekyll/converters/wordpress.rb +54 -0
  15. data/lib/jekyll/convertible.rb +71 -0
  16. data/lib/jekyll/core_ext.rb +22 -0
  17. data/lib/jekyll/filters.rb +39 -0
  18. data/lib/jekyll/layout.rb +33 -0
  19. data/lib/jekyll/page.rb +64 -0
  20. data/lib/jekyll/post.rb +194 -0
  21. data/lib/jekyll/site.rb +173 -0
  22. data/lib/jekyll/tags/highlight.rb +53 -0
  23. data/lib/jekyll/tags/include.rb +31 -0
  24. data/test/helper.rb +14 -0
  25. data/test/source/_includes/sig.markdown +3 -0
  26. data/test/source/_layouts/default.html +27 -0
  27. data/test/source/_layouts/simple.html +1 -0
  28. data/test/source/_posts/2008-02-02-not-published.textile +8 -0
  29. data/test/source/_posts/2008-02-02-published.textile +8 -0
  30. data/test/source/_posts/2008-10-18-foo-bar.textile +8 -0
  31. data/test/source/_posts/2008-11-21-complex.textile +8 -0
  32. data/test/source/_posts/2008-12-03-permalinked-post.textile +9 -0
  33. data/test/source/_posts/2008-12-13-include.markdown +8 -0
  34. data/test/source/_posts/2009-01-27-categories.textile +7 -0
  35. data/test/source/_posts/2009-01-27-category.textile +7 -0
  36. data/test/source/category/_posts/2008-9-23-categories.textile +6 -0
  37. data/test/source/css/screen.css +76 -0
  38. data/test/source/foo/_posts/bar/2008-12-12-topical-post.textile +8 -0
  39. data/test/source/index.html +22 -0
  40. data/test/source/z_category/_posts/2008-9-23-categories.textile +6 -0
  41. data/test/suite.rb +9 -0
  42. data/test/test_filters.rb +37 -0
  43. data/test/test_generated_site.rb +32 -0
  44. data/test/test_jekyll.rb +0 -0
  45. data/test/test_post.rb +144 -0
  46. data/test/test_site.rb +36 -0
  47. data/test/test_tags.rb +31 -0
  48. metadata +230 -0
data/test/test_site.rb ADDED
@@ -0,0 +1,36 @@
1
+ require File.dirname(__FILE__) + '/helper'
2
+
3
+ class TestSite < Test::Unit::TestCase
4
+ def setup
5
+ @source = File.join(File.dirname(__FILE__), *%w[source])
6
+ @s = Site.new(@source, dest_dir)
7
+ end
8
+
9
+ def test_site_init
10
+
11
+ end
12
+
13
+ def test_read_layouts
14
+ @s.read_layouts
15
+
16
+ assert_equal ["default", "simple"].sort, @s.layouts.keys.sort
17
+ end
18
+
19
+ def test_read_posts
20
+ @s.read_posts('')
21
+ posts = Dir[File.join(@source, '_posts/*')]
22
+ assert_equal posts.size - 1, @s.posts.size
23
+ end
24
+
25
+ def test_site_payload
26
+ clear_dest
27
+ @s.process
28
+
29
+ posts = Dir[File.join(@source, "**", "_posts/*")]
30
+ categories = %w(bar baz category foo z_category publish_test).sort
31
+
32
+ assert_equal posts.size - 1, @s.posts.size
33
+ assert_equal categories, @s.categories.keys.sort
34
+ assert_equal 3, @s.categories['foo'].size
35
+ end
36
+ end
data/test/test_tags.rb ADDED
@@ -0,0 +1,31 @@
1
+ require File.dirname(__FILE__) + '/helper'
2
+
3
+ class TestTags < Test::Unit::TestCase
4
+
5
+ def setup
6
+ @content = <<CONTENT
7
+ ---
8
+ layout: post
9
+ title: This is a test
10
+
11
+ ---
12
+ This document results in a markdown error with maruku
13
+ {% highlight ruby %}
14
+ puts "hi"
15
+
16
+ puts "bye"
17
+ {% endhighlight %}
18
+
19
+ CONTENT
20
+ end
21
+
22
+ def test_markdown_with_pygments_line_handling
23
+ Jekyll.pygments = true
24
+ Jekyll.content_type = :markdown
25
+
26
+ result = Liquid::Template.parse(@content).render({}, [Jekyll::Filters])
27
+ result = Jekyll.markdown_proc.call(result)
28
+ assert_no_match(/markdown\-html\-error/,result)
29
+ end
30
+
31
+ end
metadata ADDED
@@ -0,0 +1,230 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: mattmatt-jekyll
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.4.0
5
+ platform: ruby
6
+ authors:
7
+ - Tom Preston-Werner
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+
12
+ date: 2009-02-05 00:00:00 -08:00
13
+ default_executable: jekyll
14
+ dependencies:
15
+ - !ruby/object:Gem::Dependency
16
+ name: RedCloth
17
+ version_requirement:
18
+ version_requirements: !ruby/object:Gem::Requirement
19
+ requirements:
20
+ - - ">="
21
+ - !ruby/object:Gem::Version
22
+ version: 4.0.4
23
+ version:
24
+ - !ruby/object:Gem::Dependency
25
+ name: liquid
26
+ version_requirement:
27
+ version_requirements: !ruby/object:Gem::Requirement
28
+ requirements:
29
+ - - ">="
30
+ - !ruby/object:Gem::Version
31
+ version: 1.9.0
32
+ version:
33
+ - !ruby/object:Gem::Dependency
34
+ name: classifier
35
+ version_requirement:
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: 1.3.1
41
+ version:
42
+ - !ruby/object:Gem::Dependency
43
+ name: maruku
44
+ version_requirement:
45
+ version_requirements: !ruby/object:Gem::Requirement
46
+ requirements:
47
+ - - ">="
48
+ - !ruby/object:Gem::Version
49
+ version: 0.5.9
50
+ version:
51
+ - !ruby/object:Gem::Dependency
52
+ name: directory_watcher
53
+ version_requirement:
54
+ version_requirements: !ruby/object:Gem::Requirement
55
+ requirements:
56
+ - - ">="
57
+ - !ruby/object:Gem::Version
58
+ version: 1.1.1
59
+ version:
60
+ - !ruby/object:Gem::Dependency
61
+ name: open4
62
+ version_requirement:
63
+ version_requirements: !ruby/object:Gem::Requirement
64
+ requirements:
65
+ - - ">="
66
+ - !ruby/object:Gem::Version
67
+ version: 0.9.6
68
+ version:
69
+ description: Jekyll is a simple, blog aware, static site generator.
70
+ email: tom@mojombo.com
71
+ executables:
72
+ - jekyll
73
+ extensions: []
74
+
75
+ extra_rdoc_files: []
76
+
77
+ files:
78
+ - History.txt
79
+ - Rakefile
80
+ - README.textile
81
+ - TODO
82
+ - VERSION.yml
83
+ - bin/jekyll
84
+ - lib/jekyll
85
+ - lib/jekyll/albino.rb
86
+ - lib/jekyll/converters
87
+ - lib/jekyll/converters/csv.rb
88
+ - lib/jekyll/converters/mephisto.rb
89
+ - lib/jekyll/converters/mt.rb
90
+ - lib/jekyll/converters/textpattern.rb
91
+ - lib/jekyll/converters/typo.rb
92
+ - lib/jekyll/converters/wordpress.rb
93
+ - lib/jekyll/convertible.rb
94
+ - lib/jekyll/core_ext.rb
95
+ - lib/jekyll/filters.rb
96
+ - lib/jekyll/layout.rb
97
+ - lib/jekyll/page.rb
98
+ - lib/jekyll/post.rb
99
+ - lib/jekyll/site.rb
100
+ - lib/jekyll/tags
101
+ - lib/jekyll/tags/highlight.rb
102
+ - lib/jekyll/tags/include.rb
103
+ - lib/jekyll.rb
104
+ - test/dest
105
+ - test/dest/2008
106
+ - test/dest/2008/10
107
+ - test/dest/2008/10/18
108
+ - test/dest/2008/10/18/foo-bar.html
109
+ - test/dest/2008/11
110
+ - test/dest/2008/11/21
111
+ - test/dest/2008/11/21/complex.html
112
+ - test/dest/2008/12
113
+ - test/dest/2008/12/13
114
+ - test/dest/2008/12/13/include.html
115
+ - test/dest/_posts
116
+ - test/dest/_posts/2008-02-02-not-published.html
117
+ - test/dest/_posts/2008-02-02-published.html
118
+ - test/dest/_posts/2008-10-18-foo-bar.html
119
+ - test/dest/_posts/2008-11-21-complex.html
120
+ - test/dest/_posts/2008-12-03-permalinked-post.html
121
+ - test/dest/_posts/2008-12-13-include.html
122
+ - test/dest/_posts/2009-01-27-categories.html
123
+ - test/dest/_posts/2009-01-27-category.html
124
+ - test/dest/category
125
+ - test/dest/category/2008
126
+ - test/dest/category/2008/09
127
+ - test/dest/category/2008/09/23
128
+ - test/dest/category/2008/09/23/categories.html
129
+ - test/dest/category/_posts
130
+ - test/dest/category/_posts/2008-9-23-categories.html
131
+ - test/dest/css
132
+ - test/dest/css/screen.css
133
+ - test/dest/foo
134
+ - test/dest/foo/2008
135
+ - test/dest/foo/2008/12
136
+ - test/dest/foo/2008/12/12
137
+ - test/dest/foo/2008/12/12/topical-post.html
138
+ - test/dest/foo/2009
139
+ - test/dest/foo/2009/01
140
+ - test/dest/foo/2009/01/27
141
+ - test/dest/foo/2009/01/27/category.html
142
+ - test/dest/foo/_posts
143
+ - test/dest/foo/_posts/bar
144
+ - test/dest/foo/_posts/bar/2008-12-12-topical-post.html
145
+ - test/dest/foo/bar
146
+ - test/dest/foo/bar/baz
147
+ - test/dest/foo/bar/baz/2009
148
+ - test/dest/foo/bar/baz/2009/01
149
+ - test/dest/foo/bar/baz/2009/01/27
150
+ - test/dest/foo/bar/baz/2009/01/27/categories.html
151
+ - test/dest/index.html
152
+ - test/dest/my_category
153
+ - test/dest/my_category/permalinked-post
154
+ - test/dest/publish_test
155
+ - test/dest/publish_test/2008
156
+ - test/dest/publish_test/2008/02
157
+ - test/dest/publish_test/2008/02/02
158
+ - test/dest/publish_test/2008/02/02/published.html
159
+ - test/dest/z_category
160
+ - test/dest/z_category/2008
161
+ - test/dest/z_category/2008/09
162
+ - test/dest/z_category/2008/09/23
163
+ - test/dest/z_category/2008/09/23/categories.html
164
+ - test/dest/z_category/_posts
165
+ - test/dest/z_category/_posts/2008-9-23-categories.html
166
+ - test/helper.rb
167
+ - test/source
168
+ - test/source/_includes
169
+ - test/source/_includes/sig.markdown
170
+ - test/source/_layouts
171
+ - test/source/_layouts/default.html
172
+ - test/source/_layouts/simple.html
173
+ - test/source/_posts
174
+ - test/source/_posts/2008-02-02-not-published.textile
175
+ - test/source/_posts/2008-02-02-published.textile
176
+ - test/source/_posts/2008-10-18-foo-bar.textile
177
+ - test/source/_posts/2008-11-21-complex.textile
178
+ - test/source/_posts/2008-12-03-permalinked-post.textile
179
+ - test/source/_posts/2008-12-13-include.markdown
180
+ - test/source/_posts/2009-01-27-categories.textile
181
+ - test/source/_posts/2009-01-27-category.textile
182
+ - test/source/category
183
+ - test/source/category/_posts
184
+ - test/source/category/_posts/2008-9-23-categories.textile
185
+ - test/source/css
186
+ - test/source/css/screen.css
187
+ - test/source/foo
188
+ - test/source/foo/_posts
189
+ - test/source/foo/_posts/bar
190
+ - test/source/foo/_posts/bar/2008-12-12-topical-post.textile
191
+ - test/source/index.html
192
+ - test/source/z_category
193
+ - test/source/z_category/_posts
194
+ - test/source/z_category/_posts/2008-9-23-categories.textile
195
+ - test/suite.rb
196
+ - test/test_filters.rb
197
+ - test/test_generated_site.rb
198
+ - test/test_jekyll.rb
199
+ - test/test_post.rb
200
+ - test/test_site.rb
201
+ - test/test_tags.rb
202
+ has_rdoc: true
203
+ homepage: http://github.com/mojombo/jekyll
204
+ post_install_message:
205
+ rdoc_options:
206
+ - --inline-source
207
+ - --charset=UTF-8
208
+ require_paths:
209
+ - lib
210
+ required_ruby_version: !ruby/object:Gem::Requirement
211
+ requirements:
212
+ - - ">="
213
+ - !ruby/object:Gem::Version
214
+ version: "0"
215
+ version:
216
+ required_rubygems_version: !ruby/object:Gem::Requirement
217
+ requirements:
218
+ - - ">="
219
+ - !ruby/object:Gem::Version
220
+ version: "0"
221
+ version:
222
+ requirements: []
223
+
224
+ rubyforge_project: jekyll
225
+ rubygems_version: 1.2.0
226
+ signing_key:
227
+ specification_version: 2
228
+ summary: Jekyll is a simple, blog aware, static site generator.
229
+ test_files: []
230
+