jekyll 0.10.0 → 0.11.0
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.
Potentially problematic release.
This version of jekyll might be problematic. Click here for more details.
- data/Gemfile +2 -0
- data/History.txt +20 -1
- data/README.textile +1 -1
- data/Rakefile +2 -0
- data/bin/jekyll +92 -2
- data/doc/output/book.html +574 -0
- data/doc/output/ch00-preface.asc +41 -0
- data/doc/output/ch01-quick-start.asc +153 -0
- data/doc/output/ch02-directory-layout.asc +90 -0
- data/doc/output/stylesheets/handbookish-quirks.css +0 -0
- data/doc/output/stylesheets/handbookish.css +231 -0
- data/doc/output/stylesheets/scribe-quirks.css +0 -0
- data/doc/output/stylesheets/scribe.css +177 -0
- data/features/post_data.feature +2 -2
- data/features/site_configuration.feature +7 -0
- data/features/support/env.rb +3 -0
- data/g.pl +48 -0
- data/jekyll.gemspec +35 -16
- data/lib/jekyll.rb +11 -4
- data/lib/jekyll/converters/markdown.rb +14 -2
- data/lib/jekyll/converters/textile.rb +2 -1
- data/lib/jekyll/convertible.rb +34 -19
- data/lib/jekyll/filters.rb +66 -1
- data/lib/jekyll/generators/pagination.rb +33 -7
- data/lib/jekyll/layout.rb +18 -10
- data/lib/jekyll/migrators/csv.rb +3 -3
- data/lib/jekyll/migrators/drupal.rb +12 -6
- data/lib/jekyll/migrators/enki.rb +49 -0
- data/lib/jekyll/migrators/marley.rb +0 -1
- data/lib/jekyll/migrators/mephisto.rb +17 -12
- data/lib/jekyll/migrators/mt.rb +26 -17
- data/lib/jekyll/migrators/posterous.rb +68 -0
- data/lib/jekyll/migrators/textpattern.rb +15 -8
- data/lib/jekyll/migrators/tumblr.rb +119 -0
- data/lib/jekyll/migrators/typo.rb +8 -6
- data/lib/jekyll/migrators/wordpress.rb +23 -16
- data/lib/jekyll/migrators/wordpressdotcom.rb +70 -0
- data/lib/jekyll/page.rb +56 -35
- data/lib/jekyll/plugin.rb +1 -0
- data/lib/jekyll/post.rb +25 -14
- data/lib/jekyll/site.rb +138 -80
- data/lib/jekyll/static_file.rb +12 -15
- data/lib/jekyll/tags/highlight.rb +5 -5
- data/output/stylesheets/scribe-quirks.css +0 -0
- data/output/stylesheets/scribe.css +177 -0
- data/test/helper.rb +3 -3
- data/test/source/_posts/2011-04-12-md-extension.md +7 -0
- data/test/source/_posts/2011-04-12-text-extension.text +0 -0
- data/test/suite.rb +3 -1
- data/test/test_configuration.rb +1 -1
- data/test/test_core_ext.rb +1 -1
- data/test/test_filters.rb +10 -1
- data/test/test_generated_site.rb +2 -2
- data/test/test_kramdown.rb +1 -1
- data/test/test_page.rb +1 -1
- data/test/test_pager.rb +1 -1
- data/test/test_post.rb +49 -2
- data/test/test_rdiscount.rb +1 -1
- data/test/test_redcarpet.rb +21 -0
- data/test/test_site.rb +1 -1
- data/test/test_tags.rb +14 -1
- metadata +104 -38
- data/lib/jekyll/albino.rb +0 -120
- data/lib/jekyll/migrators/wordpress.com.rb +0 -38
data/test/test_rdiscount.rb
CHANGED
@@ -0,0 +1,21 @@
|
|
1
|
+
require File.dirname(__FILE__) + '/helper'
|
2
|
+
|
3
|
+
class TestRedcarpet < Test::Unit::TestCase
|
4
|
+
context "redcarpet" do
|
5
|
+
setup do
|
6
|
+
config = {
|
7
|
+
'redcarpet' => { 'extensions' => ['smart'] },
|
8
|
+
'markdown' => 'redcarpet'
|
9
|
+
}
|
10
|
+
@markdown = MarkdownConverter.new config
|
11
|
+
end
|
12
|
+
|
13
|
+
should "pass redcarpet options" do
|
14
|
+
assert_equal "<h1>Some Header</h1>", @markdown.convert('# Some Header #').strip
|
15
|
+
end
|
16
|
+
|
17
|
+
should "pass redcarpet extensions" do
|
18
|
+
assert_equal "<p>“smart”</p>", @markdown.convert('"smart"').strip
|
19
|
+
end
|
20
|
+
end
|
21
|
+
end
|
data/test/test_site.rb
CHANGED
data/test/test_tags.rb
CHANGED
@@ -1,4 +1,6 @@
|
|
1
|
-
|
1
|
+
# coding: utf-8
|
2
|
+
|
3
|
+
require 'helper'
|
2
4
|
|
3
5
|
class TestTags < Test::Unit::TestCase
|
4
6
|
|
@@ -123,5 +125,16 @@ CONTENT
|
|
123
125
|
assert_match %r{<em>FINISH HIM</em>}, @result
|
124
126
|
end
|
125
127
|
end
|
128
|
+
|
129
|
+
context "using Redcarpet" do
|
130
|
+
setup do
|
131
|
+
create_post(@content, 'markdown' => 'redcarpet')
|
132
|
+
end
|
133
|
+
|
134
|
+
should "parse correctly" do
|
135
|
+
assert_match %r{<em>FIGHT!</em>}, @result
|
136
|
+
assert_match %r{<em>FINISH HIM</em>}, @result
|
137
|
+
end
|
138
|
+
end
|
126
139
|
end
|
127
140
|
end
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jekyll
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 51
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
|
-
-
|
8
|
+
- 11
|
9
9
|
- 0
|
10
|
-
version: 0.
|
10
|
+
version: 0.11.0
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Tom Preston-Werner
|
@@ -15,8 +15,8 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date:
|
19
|
-
default_executable:
|
18
|
+
date: 2011-07-10 00:00:00 -07:00
|
19
|
+
default_executable:
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|
22
22
|
name: liquid
|
@@ -83,73 +83,105 @@ dependencies:
|
|
83
83
|
type: :runtime
|
84
84
|
version_requirements: *id004
|
85
85
|
- !ruby/object:Gem::Dependency
|
86
|
-
name:
|
86
|
+
name: kramdown
|
87
87
|
prerelease: false
|
88
88
|
requirement: &id005 !ruby/object:Gem::Requirement
|
89
89
|
none: false
|
90
90
|
requirements:
|
91
91
|
- - ">="
|
92
92
|
- !ruby/object:Gem::Version
|
93
|
-
hash:
|
93
|
+
hash: 47
|
94
94
|
segments:
|
95
|
-
-
|
95
|
+
- 0
|
96
|
+
- 13
|
96
97
|
- 2
|
97
|
-
|
98
|
-
|
99
|
-
type: :development
|
98
|
+
version: 0.13.2
|
99
|
+
type: :runtime
|
100
100
|
version_requirements: *id005
|
101
101
|
- !ruby/object:Gem::Dependency
|
102
|
-
name:
|
102
|
+
name: albino
|
103
103
|
prerelease: false
|
104
104
|
requirement: &id006 !ruby/object:Gem::Requirement
|
105
105
|
none: false
|
106
106
|
requirements:
|
107
107
|
- - ">="
|
108
108
|
- !ruby/object:Gem::Version
|
109
|
-
hash:
|
109
|
+
hash: 31
|
110
110
|
segments:
|
111
|
-
- 4
|
112
|
-
- 2
|
113
111
|
- 1
|
114
|
-
|
115
|
-
|
112
|
+
- 3
|
113
|
+
- 2
|
114
|
+
version: 1.3.2
|
115
|
+
type: :runtime
|
116
116
|
version_requirements: *id006
|
117
117
|
- !ruby/object:Gem::Dependency
|
118
|
-
name:
|
118
|
+
name: redgreen
|
119
119
|
prerelease: false
|
120
120
|
requirement: &id007 !ruby/object:Gem::Requirement
|
121
121
|
none: false
|
122
122
|
requirements:
|
123
123
|
- - ">="
|
124
124
|
- !ruby/object:Gem::Version
|
125
|
-
hash:
|
125
|
+
hash: 27
|
126
126
|
segments:
|
127
|
-
- 4
|
128
|
-
- 2
|
129
127
|
- 1
|
130
|
-
|
128
|
+
- 2
|
129
|
+
- 2
|
130
|
+
version: 1.2.2
|
131
131
|
type: :development
|
132
132
|
version_requirements: *id007
|
133
133
|
- !ruby/object:Gem::Dependency
|
134
|
-
name:
|
134
|
+
name: shoulda
|
135
135
|
prerelease: false
|
136
136
|
requirement: &id008 !ruby/object:Gem::Requirement
|
137
137
|
none: false
|
138
138
|
requirements:
|
139
139
|
- - ">="
|
140
140
|
- !ruby/object:Gem::Version
|
141
|
-
hash:
|
141
|
+
hash: 37
|
142
142
|
segments:
|
143
|
-
- 4
|
144
143
|
- 2
|
145
|
-
-
|
146
|
-
|
144
|
+
- 11
|
145
|
+
- 3
|
146
|
+
version: 2.11.3
|
147
147
|
type: :development
|
148
148
|
version_requirements: *id008
|
149
149
|
- !ruby/object:Gem::Dependency
|
150
|
-
name:
|
150
|
+
name: rr
|
151
151
|
prerelease: false
|
152
152
|
requirement: &id009 !ruby/object:Gem::Requirement
|
153
|
+
none: false
|
154
|
+
requirements:
|
155
|
+
- - ">="
|
156
|
+
- !ruby/object:Gem::Version
|
157
|
+
hash: 19
|
158
|
+
segments:
|
159
|
+
- 1
|
160
|
+
- 0
|
161
|
+
- 2
|
162
|
+
version: 1.0.2
|
163
|
+
type: :development
|
164
|
+
version_requirements: *id009
|
165
|
+
- !ruby/object:Gem::Dependency
|
166
|
+
name: cucumber
|
167
|
+
prerelease: false
|
168
|
+
requirement: &id010 !ruby/object:Gem::Requirement
|
169
|
+
none: false
|
170
|
+
requirements:
|
171
|
+
- - ">="
|
172
|
+
- !ruby/object:Gem::Version
|
173
|
+
hash: 49
|
174
|
+
segments:
|
175
|
+
- 0
|
176
|
+
- 10
|
177
|
+
- 3
|
178
|
+
version: 0.10.3
|
179
|
+
type: :development
|
180
|
+
version_requirements: *id010
|
181
|
+
- !ruby/object:Gem::Dependency
|
182
|
+
name: RedCloth
|
183
|
+
prerelease: false
|
184
|
+
requirement: &id011 !ruby/object:Gem::Requirement
|
153
185
|
none: false
|
154
186
|
requirements:
|
155
187
|
- - ">="
|
@@ -161,23 +193,39 @@ dependencies:
|
|
161
193
|
- 1
|
162
194
|
version: 4.2.1
|
163
195
|
type: :development
|
164
|
-
version_requirements: *
|
196
|
+
version_requirements: *id011
|
165
197
|
- !ruby/object:Gem::Dependency
|
166
|
-
name:
|
198
|
+
name: rdiscount
|
167
199
|
prerelease: false
|
168
|
-
requirement: &
|
200
|
+
requirement: &id012 !ruby/object:Gem::Requirement
|
169
201
|
none: false
|
170
202
|
requirements:
|
171
203
|
- - ">="
|
172
204
|
- !ruby/object:Gem::Version
|
173
|
-
hash:
|
205
|
+
hash: 5
|
174
206
|
segments:
|
207
|
+
- 1
|
208
|
+
- 6
|
209
|
+
- 5
|
210
|
+
version: 1.6.5
|
211
|
+
type: :development
|
212
|
+
version_requirements: *id012
|
213
|
+
- !ruby/object:Gem::Dependency
|
214
|
+
name: redcarpet
|
215
|
+
prerelease: false
|
216
|
+
requirement: &id013 !ruby/object:Gem::Requirement
|
217
|
+
none: false
|
218
|
+
requirements:
|
219
|
+
- - ">="
|
220
|
+
- !ruby/object:Gem::Version
|
221
|
+
hash: 51
|
222
|
+
segments:
|
223
|
+
- 1
|
224
|
+
- 9
|
175
225
|
- 0
|
176
|
-
|
177
|
-
- 0
|
178
|
-
version: 0.12.0
|
226
|
+
version: 1.9.0
|
179
227
|
type: :development
|
180
|
-
version_requirements: *
|
228
|
+
version_requirements: *id013
|
181
229
|
description: Jekyll is a simple, blog aware, static site generator.
|
182
230
|
email: tom@mojombo.com
|
183
231
|
executables:
|
@@ -188,12 +236,21 @@ extra_rdoc_files:
|
|
188
236
|
- README.textile
|
189
237
|
- LICENSE
|
190
238
|
files:
|
239
|
+
- Gemfile
|
191
240
|
- History.txt
|
192
241
|
- LICENSE
|
193
242
|
- README.textile
|
194
243
|
- Rakefile
|
195
244
|
- bin/jekyll
|
196
245
|
- cucumber.yml
|
246
|
+
- doc/output/book.html
|
247
|
+
- doc/output/ch00-preface.asc
|
248
|
+
- doc/output/ch01-quick-start.asc
|
249
|
+
- doc/output/ch02-directory-layout.asc
|
250
|
+
- doc/output/stylesheets/handbookish-quirks.css
|
251
|
+
- doc/output/stylesheets/handbookish.css
|
252
|
+
- doc/output/stylesheets/scribe-quirks.css
|
253
|
+
- doc/output/stylesheets/scribe.css
|
197
254
|
- features/create_sites.feature
|
198
255
|
- features/embed_filters.feature
|
199
256
|
- features/markdown.feature
|
@@ -204,9 +261,9 @@ files:
|
|
204
261
|
- features/site_data.feature
|
205
262
|
- features/step_definitions/jekyll_steps.rb
|
206
263
|
- features/support/env.rb
|
264
|
+
- g.pl
|
207
265
|
- jekyll.gemspec
|
208
266
|
- lib/jekyll.rb
|
209
|
-
- lib/jekyll/albino.rb
|
210
267
|
- lib/jekyll/converter.rb
|
211
268
|
- lib/jekyll/converters/identity.rb
|
212
269
|
- lib/jekyll/converters/markdown.rb
|
@@ -220,13 +277,16 @@ files:
|
|
220
277
|
- lib/jekyll/layout.rb
|
221
278
|
- lib/jekyll/migrators/csv.rb
|
222
279
|
- lib/jekyll/migrators/drupal.rb
|
280
|
+
- lib/jekyll/migrators/enki.rb
|
223
281
|
- lib/jekyll/migrators/marley.rb
|
224
282
|
- lib/jekyll/migrators/mephisto.rb
|
225
283
|
- lib/jekyll/migrators/mt.rb
|
284
|
+
- lib/jekyll/migrators/posterous.rb
|
226
285
|
- lib/jekyll/migrators/textpattern.rb
|
286
|
+
- lib/jekyll/migrators/tumblr.rb
|
227
287
|
- lib/jekyll/migrators/typo.rb
|
228
|
-
- lib/jekyll/migrators/wordpress.com.rb
|
229
288
|
- lib/jekyll/migrators/wordpress.rb
|
289
|
+
- lib/jekyll/migrators/wordpressdotcom.rb
|
230
290
|
- lib/jekyll/page.rb
|
231
291
|
- lib/jekyll/plugin.rb
|
232
292
|
- lib/jekyll/post.rb
|
@@ -234,6 +294,8 @@ files:
|
|
234
294
|
- lib/jekyll/static_file.rb
|
235
295
|
- lib/jekyll/tags/highlight.rb
|
236
296
|
- lib/jekyll/tags/include.rb
|
297
|
+
- output/stylesheets/scribe-quirks.css
|
298
|
+
- output/stylesheets/scribe.css
|
237
299
|
- test/helper.rb
|
238
300
|
- test/source/.htaccess
|
239
301
|
- test/source/_includes/sig.markdown
|
@@ -262,6 +324,8 @@ files:
|
|
262
324
|
- test/source/_posts/2010-01-09-time-override.textile
|
263
325
|
- test/source/_posts/2010-01-09-timezone-override.textile
|
264
326
|
- test/source/_posts/2010-01-16-override-data.textile
|
327
|
+
- test/source/_posts/2011-04-12-md-extension.md
|
328
|
+
- test/source/_posts/2011-04-12-text-extension.text
|
265
329
|
- test/source/about.html
|
266
330
|
- test/source/category/_posts/2008-9-23-categories.textile
|
267
331
|
- test/source/contacts.html
|
@@ -282,6 +346,7 @@ files:
|
|
282
346
|
- test/test_pager.rb
|
283
347
|
- test/test_post.rb
|
284
348
|
- test/test_rdiscount.rb
|
349
|
+
- test/test_redcarpet.rb
|
285
350
|
- test/test_site.rb
|
286
351
|
- test/test_tags.rb
|
287
352
|
has_rdoc: true
|
@@ -328,5 +393,6 @@ test_files:
|
|
328
393
|
- test/test_pager.rb
|
329
394
|
- test/test_post.rb
|
330
395
|
- test/test_rdiscount.rb
|
396
|
+
- test/test_redcarpet.rb
|
331
397
|
- test/test_site.rb
|
332
398
|
- test/test_tags.rb
|
data/lib/jekyll/albino.rb
DELETED
@@ -1,120 +0,0 @@
|
|
1
|
-
##
|
2
|
-
# Wrapper for the Pygments command line tool, pygmentize.
|
3
|
-
#
|
4
|
-
# Pygments: http://pygments.org/
|
5
|
-
#
|
6
|
-
# Assumes pygmentize is in the path. If not, set its location
|
7
|
-
# with Albino.bin = '/path/to/pygmentize'
|
8
|
-
#
|
9
|
-
# Use like so:
|
10
|
-
#
|
11
|
-
# @syntaxer = Albino.new('/some/file.rb', :ruby)
|
12
|
-
# puts @syntaxer.colorize
|
13
|
-
#
|
14
|
-
# This'll print out an HTMLized, Ruby-highlighted version
|
15
|
-
# of '/some/file.rb'.
|
16
|
-
#
|
17
|
-
# To use another formatter, pass it as the third argument:
|
18
|
-
#
|
19
|
-
# @syntaxer = Albino.new('/some/file.rb', :ruby, :bbcode)
|
20
|
-
# puts @syntaxer.colorize
|
21
|
-
#
|
22
|
-
# You can also use the #colorize class method:
|
23
|
-
#
|
24
|
-
# puts Albino.colorize('/some/file.rb', :ruby)
|
25
|
-
#
|
26
|
-
# Another also: you get a #to_s, for somewhat nicer use in Rails views.
|
27
|
-
#
|
28
|
-
# ... helper file ...
|
29
|
-
# def highlight(text)
|
30
|
-
# Albino.new(text, :ruby)
|
31
|
-
# end
|
32
|
-
#
|
33
|
-
# ... view file ...
|
34
|
-
# <%= highlight text %>
|
35
|
-
#
|
36
|
-
# The default lexer is 'text'. You need to specify a lexer yourself;
|
37
|
-
# because we are using STDIN there is no auto-detect.
|
38
|
-
#
|
39
|
-
# To see all lexers and formatters available, run `pygmentize -L`.
|
40
|
-
#
|
41
|
-
# Chris Wanstrath // chris@ozmm.org
|
42
|
-
# GitHub // http://github.com
|
43
|
-
#
|
44
|
-
|
45
|
-
class Albino
|
46
|
-
@@bin = Rails.development? ? 'pygmentize' : '/usr/bin/pygmentize' rescue 'pygmentize'
|
47
|
-
|
48
|
-
def self.bin=(path)
|
49
|
-
@@bin = path
|
50
|
-
end
|
51
|
-
|
52
|
-
def self.colorize(*args)
|
53
|
-
new(*args).colorize
|
54
|
-
end
|
55
|
-
|
56
|
-
def initialize(target, lexer = :text, format = :html)
|
57
|
-
@target = target
|
58
|
-
@options = { :l => lexer, :f => format, :O => 'encoding=utf-8' }
|
59
|
-
end
|
60
|
-
|
61
|
-
def execute(command)
|
62
|
-
output = ''
|
63
|
-
IO.popen(command, mode='r+') do |p|
|
64
|
-
p.write @target
|
65
|
-
p.close_write
|
66
|
-
output = p.read.strip
|
67
|
-
end
|
68
|
-
output
|
69
|
-
end
|
70
|
-
|
71
|
-
def colorize(options = {})
|
72
|
-
html = execute(@@bin + convert_options(options))
|
73
|
-
# Work around an RDiscount bug: http://gist.github.com/97682
|
74
|
-
html.to_s.sub(%r{</pre></div>\Z}, "</pre>\n</div>")
|
75
|
-
end
|
76
|
-
alias_method :to_s, :colorize
|
77
|
-
|
78
|
-
def convert_options(options = {})
|
79
|
-
@options.merge(options).inject('') do |string, (flag, value)|
|
80
|
-
string + " -#{flag} #{value}"
|
81
|
-
end
|
82
|
-
end
|
83
|
-
end
|
84
|
-
|
85
|
-
if $0 == __FILE__
|
86
|
-
require 'rubygems'
|
87
|
-
require 'test/spec'
|
88
|
-
require 'mocha'
|
89
|
-
begin require 'redgreen'; rescue LoadError; end
|
90
|
-
|
91
|
-
context "Albino" do
|
92
|
-
setup do
|
93
|
-
@syntaxer = Albino.new(__FILE__, :ruby)
|
94
|
-
end
|
95
|
-
|
96
|
-
specify "defaults to text" do
|
97
|
-
syntaxer = Albino.new(__FILE__)
|
98
|
-
syntaxer.expects(:execute).with('pygmentize -f html -l text').returns(true)
|
99
|
-
syntaxer.colorize
|
100
|
-
end
|
101
|
-
|
102
|
-
specify "accepts options" do
|
103
|
-
@syntaxer.expects(:execute).with('pygmentize -f html -l ruby').returns(true)
|
104
|
-
@syntaxer.colorize
|
105
|
-
end
|
106
|
-
|
107
|
-
specify "works with strings" do
|
108
|
-
syntaxer = Albino.new('class New; end', :ruby)
|
109
|
-
assert_match %r(highlight), syntaxer.colorize
|
110
|
-
end
|
111
|
-
|
112
|
-
specify "aliases to_s" do
|
113
|
-
assert_equal @syntaxer.colorize, @syntaxer.to_s
|
114
|
-
end
|
115
|
-
|
116
|
-
specify "class method colorize" do
|
117
|
-
assert_equal @syntaxer.colorize, Albino.colorize(__FILE__, :ruby)
|
118
|
-
end
|
119
|
-
end
|
120
|
-
end
|