tilt 1.2.2 → 1.3
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +54 -24
- data/TEMPLATES.md +250 -175
- data/lib/tilt.rb +104 -817
- data/lib/tilt/builder.rb +40 -0
- data/lib/tilt/coffee.rb +50 -0
- data/lib/tilt/creole.rb +28 -0
- data/lib/tilt/css.rb +67 -0
- data/lib/tilt/erb.rb +110 -0
- data/lib/tilt/haml.rb +64 -0
- data/lib/tilt/liquid.rb +41 -0
- data/lib/tilt/markaby.rb +52 -0
- data/lib/tilt/markdown.rb +131 -0
- data/lib/tilt/nokogiri.rb +43 -0
- data/lib/tilt/radius.rb +51 -0
- data/lib/tilt/rdoc.rb +32 -0
- data/lib/tilt/string.rb +21 -0
- data/lib/tilt/template.rb +285 -0
- data/lib/tilt/textile.rb +25 -0
- data/test/tilt_blueclothtemplate_test.rb +6 -25
- data/test/tilt_coffeescripttemplate_test.rb +31 -1
- data/test/tilt_creoletemplate_test.rb +24 -0
- data/test/tilt_erbtemplate_test.rb +18 -19
- data/test/tilt_erubistemplate_test.rb +12 -2
- data/test/tilt_fallback_test.rb +122 -0
- data/test/tilt_hamltemplate_test.rb +4 -4
- data/test/tilt_kramdown_test.rb +42 -0
- data/test/tilt_markdown_test.rb +149 -0
- data/test/tilt_marukutemplate_test.rb +48 -0
- data/test/tilt_rdiscounttemplate_test.rb +16 -6
- data/test/tilt_redcarpettemplate_test.rb +55 -0
- data/test/tilt_stringtemplate_test.rb +10 -3
- data/test/tilt_template_test.rb +6 -0
- data/tilt.gemspec +28 -2
- metadata +86 -36
@@ -0,0 +1,149 @@
|
|
1
|
+
# coding: UTF-8
|
2
|
+
require 'tilt'
|
3
|
+
require 'nokogiri'
|
4
|
+
|
5
|
+
module MarkdownTests
|
6
|
+
def self.included(mod)
|
7
|
+
class << mod
|
8
|
+
def template(t = nil)
|
9
|
+
t.nil? ? @template : @template = t
|
10
|
+
end
|
11
|
+
end
|
12
|
+
end
|
13
|
+
|
14
|
+
def render(text, options = {})
|
15
|
+
self.class.template.new(options) { text }.render
|
16
|
+
end
|
17
|
+
|
18
|
+
def normalize(html)
|
19
|
+
Nokogiri::HTML.fragment(html).to_s
|
20
|
+
end
|
21
|
+
|
22
|
+
def nrender(text, options = {})
|
23
|
+
html = render(text, options)
|
24
|
+
html.encode!("UTF-8") if html.respond_to?(:encode)
|
25
|
+
normalize(html)
|
26
|
+
end
|
27
|
+
|
28
|
+
def test_escape_html
|
29
|
+
html = nrender "Hello <b>World</b>"
|
30
|
+
assert_equal "<p>Hello <b>World</b></p>", html
|
31
|
+
end
|
32
|
+
|
33
|
+
def test_escape_html_false
|
34
|
+
html = nrender "Hello <b>World</b>", :escape_html => false
|
35
|
+
assert_equal "<p>Hello <b>World</b></p>", html
|
36
|
+
end
|
37
|
+
|
38
|
+
def test_escape_html_true
|
39
|
+
html = nrender "Hello <b>World</b>", :escape_html => true
|
40
|
+
assert_equal "<p>Hello <b>World</b></p>", html
|
41
|
+
end
|
42
|
+
|
43
|
+
def test_smart_quotes
|
44
|
+
html = nrender 'Hello "World"'
|
45
|
+
assert_equal '<p>Hello "World"</p>', html
|
46
|
+
end
|
47
|
+
|
48
|
+
def test_smart_quotes_false
|
49
|
+
html = nrender 'Hello "World"', :smartypants => false
|
50
|
+
assert_equal '<p>Hello "World"</p>', html
|
51
|
+
end
|
52
|
+
|
53
|
+
def test_smart_quotes_true
|
54
|
+
html = nrender 'Hello "World"', :smartypants => true
|
55
|
+
assert_equal '<p>Hello “World”</p>', html
|
56
|
+
end
|
57
|
+
|
58
|
+
def test_smarty_pants
|
59
|
+
html = nrender "Hello ``World'' -- This is --- a test ..."
|
60
|
+
assert_equal "<p>Hello ``World'' -- This is --- a test ...</p>", html
|
61
|
+
end
|
62
|
+
|
63
|
+
def test_smarty_pants_false
|
64
|
+
html = nrender "Hello ``World'' -- This is --- a test ...", :smartypants => false
|
65
|
+
assert_equal "<p>Hello ``World'' -- This is --- a test ...</p>", html
|
66
|
+
end
|
67
|
+
|
68
|
+
def test_smarty_pants_true
|
69
|
+
if self.class.template == Tilt::RedcarpetTemplate
|
70
|
+
warn "\nsmartypants not yet fully supported by redcarpet (#{__FILE__}:#{__LINE__})"
|
71
|
+
else
|
72
|
+
html = nrender "Hello ``World'' -- This is --- a test ...", :smartypants => true
|
73
|
+
assert_equal "<p>Hello “World” — This is —– a test …</p>", html
|
74
|
+
end
|
75
|
+
end
|
76
|
+
end
|
77
|
+
|
78
|
+
begin
|
79
|
+
require 'rdiscount'
|
80
|
+
|
81
|
+
class MarkdownRDiscountTest < Test::Unit::TestCase
|
82
|
+
include MarkdownTests
|
83
|
+
template Tilt::RDiscountTemplate
|
84
|
+
end
|
85
|
+
rescue LoadError => boom
|
86
|
+
# It should already be warned in the main tests
|
87
|
+
end
|
88
|
+
|
89
|
+
begin
|
90
|
+
require 'redcarpet'
|
91
|
+
|
92
|
+
class MarkdownRedcarpetTest < Test::Unit::TestCase
|
93
|
+
include MarkdownTests
|
94
|
+
template Tilt::RedcarpetTemplate
|
95
|
+
end
|
96
|
+
rescue LoadError => boom
|
97
|
+
# It should already be warned in the main tests
|
98
|
+
end
|
99
|
+
|
100
|
+
begin
|
101
|
+
require 'bluecloth'
|
102
|
+
|
103
|
+
class MarkdownBlueClothTest < Test::Unit::TestCase
|
104
|
+
include MarkdownTests
|
105
|
+
template Tilt::BlueClothTemplate
|
106
|
+
end
|
107
|
+
rescue LoadError => boom
|
108
|
+
# It should already be warned in the main tests
|
109
|
+
end
|
110
|
+
|
111
|
+
begin
|
112
|
+
require 'kramdown'
|
113
|
+
|
114
|
+
class MarkdownKramdownTest < Test::Unit::TestCase
|
115
|
+
include MarkdownTests
|
116
|
+
template Tilt::KramdownTemplate
|
117
|
+
# Doesn't support escaping
|
118
|
+
undef test_escape_html_true
|
119
|
+
# Smarty Pants is *always* on, but doesn't support it fully
|
120
|
+
undef test_smarty_pants
|
121
|
+
undef test_smarty_pants_false
|
122
|
+
undef test_smarty_pants_true
|
123
|
+
end
|
124
|
+
rescue LoadError => boom
|
125
|
+
# It should already be warned in the main tests
|
126
|
+
end
|
127
|
+
|
128
|
+
|
129
|
+
begin
|
130
|
+
require 'maruku'
|
131
|
+
|
132
|
+
class MarkdownMarukuTest < Test::Unit::TestCase
|
133
|
+
include MarkdownTests
|
134
|
+
template Tilt::MarukuTemplate
|
135
|
+
# Doesn't support escaping
|
136
|
+
undef test_escape_html_true
|
137
|
+
# Doesn't support Smarty Pants, and even fails on ``Foobar''
|
138
|
+
undef test_smarty_pants
|
139
|
+
undef test_smarty_pants_false
|
140
|
+
undef test_smarty_pants_true
|
141
|
+
# Smart Quotes is always on
|
142
|
+
undef test_smart_quotes
|
143
|
+
undef test_smart_quotes_false
|
144
|
+
end
|
145
|
+
rescue LoadError => boom
|
146
|
+
# It should already be warned in the main tests
|
147
|
+
end
|
148
|
+
|
149
|
+
|
@@ -0,0 +1,48 @@
|
|
1
|
+
require 'contest'
|
2
|
+
require 'tilt'
|
3
|
+
|
4
|
+
begin
|
5
|
+
require 'maruku'
|
6
|
+
|
7
|
+
class MarukuTemplateTest < Test::Unit::TestCase
|
8
|
+
test "registered for '.md' files" do
|
9
|
+
assert Tilt.mappings['md'].include?(Tilt::MarukuTemplate)
|
10
|
+
end
|
11
|
+
|
12
|
+
test "registered for '.mkd' files" do
|
13
|
+
assert Tilt.mappings['mkd'].include?(Tilt::MarukuTemplate)
|
14
|
+
end
|
15
|
+
|
16
|
+
test "registered for '.markdown' files" do
|
17
|
+
assert Tilt.mappings['markdown'].include?(Tilt::MarukuTemplate)
|
18
|
+
end
|
19
|
+
|
20
|
+
test "registered below Kramdown" do
|
21
|
+
%w[md mkd markdown].each do |ext|
|
22
|
+
mappings = Tilt.mappings[ext]
|
23
|
+
kram_idx = mappings.index(Tilt::KramdownTemplate)
|
24
|
+
maru_idx = mappings.index(Tilt::MarukuTemplate)
|
25
|
+
assert maru_idx > kram_idx,
|
26
|
+
"#{maru_idx} should be higher than #{kram_idx}"
|
27
|
+
end
|
28
|
+
end
|
29
|
+
|
30
|
+
test "preparing and evaluating templates on #render" do
|
31
|
+
template = Tilt::MarukuTemplate.new { |t| "# Hello World!" }
|
32
|
+
assert_equal "<h1 id='hello_world'>Hello World!</h1>", template.render
|
33
|
+
end
|
34
|
+
|
35
|
+
test "can be rendered more than once" do
|
36
|
+
template = Tilt::MarukuTemplate.new { |t| "# Hello World!" }
|
37
|
+
3.times { assert_equal "<h1 id='hello_world'>Hello World!</h1>", template.render }
|
38
|
+
end
|
39
|
+
|
40
|
+
test "removes HTML when :filter_html is set" do
|
41
|
+
template = Tilt::MarukuTemplate.new(:filter_html => true) { |t|
|
42
|
+
"HELLO <blink>WORLD</blink>" }
|
43
|
+
assert_equal "<p>HELLO </p>", template.render
|
44
|
+
end
|
45
|
+
end
|
46
|
+
rescue LoadError => boom
|
47
|
+
warn "Tilt::MarukuTemplate (disabled)\n"
|
48
|
+
end
|
@@ -5,16 +5,26 @@ begin
|
|
5
5
|
require 'rdiscount'
|
6
6
|
|
7
7
|
class RDiscountTemplateTest < Test::Unit::TestCase
|
8
|
-
test "registered for '.markdown' files" do
|
9
|
-
assert_equal Tilt::RDiscountTemplate, Tilt['test.markdown']
|
10
|
-
end
|
11
|
-
|
12
8
|
test "registered for '.md' files" do
|
13
|
-
|
9
|
+
assert Tilt.mappings['md'].include?(Tilt::RDiscountTemplate)
|
14
10
|
end
|
15
11
|
|
16
12
|
test "registered for '.mkd' files" do
|
17
|
-
|
13
|
+
assert Tilt.mappings['mkd'].include?(Tilt::RDiscountTemplate)
|
14
|
+
end
|
15
|
+
|
16
|
+
test "registered for '.markdown' files" do
|
17
|
+
assert Tilt.mappings['markdown'].include?(Tilt::RDiscountTemplate)
|
18
|
+
end
|
19
|
+
|
20
|
+
test "registered above BlueCloth" do
|
21
|
+
%w[md mkd markdown].each do |ext|
|
22
|
+
mappings = Tilt.mappings[ext]
|
23
|
+
blue_idx = mappings.index(Tilt::BlueClothTemplate)
|
24
|
+
rdis_idx = mappings.index(Tilt::RDiscountTemplate)
|
25
|
+
assert rdis_idx < blue_idx,
|
26
|
+
"#{rdis_idx} should be lower than #{blue_idx}"
|
27
|
+
end
|
18
28
|
end
|
19
29
|
|
20
30
|
test "preparing and evaluating templates on #render" do
|
@@ -0,0 +1,55 @@
|
|
1
|
+
require 'contest'
|
2
|
+
require 'tilt'
|
3
|
+
|
4
|
+
begin
|
5
|
+
require 'redcarpet'
|
6
|
+
|
7
|
+
class RedcarpetTemplateTest < Test::Unit::TestCase
|
8
|
+
test "registered for '.md' files" do
|
9
|
+
assert Tilt.mappings['md'].include?(Tilt::RedcarpetTemplate)
|
10
|
+
end
|
11
|
+
|
12
|
+
test "registered for '.mkd' files" do
|
13
|
+
assert Tilt.mappings['mkd'].include?(Tilt::RedcarpetTemplate)
|
14
|
+
end
|
15
|
+
|
16
|
+
test "registered for '.markdown' files" do
|
17
|
+
assert Tilt.mappings['markdown'].include?(Tilt::RedcarpetTemplate)
|
18
|
+
end
|
19
|
+
|
20
|
+
test "registered above BlueCloth" do
|
21
|
+
%w[md mkd markdown].each do |ext|
|
22
|
+
mappings = Tilt.mappings[ext]
|
23
|
+
blue_idx = mappings.index(Tilt::BlueClothTemplate)
|
24
|
+
rdis_idx = mappings.index(Tilt::RedcarpetTemplate)
|
25
|
+
assert rdis_idx < blue_idx,
|
26
|
+
"#{rdis_idx} should be lower than #{blue_idx}"
|
27
|
+
end
|
28
|
+
end
|
29
|
+
|
30
|
+
test "preparing and evaluating templates on #render" do
|
31
|
+
template = Tilt::RedcarpetTemplate.new { |t| "# Hello World!" }
|
32
|
+
assert_equal "<h1>Hello World!</h1>\n", template.render
|
33
|
+
end
|
34
|
+
|
35
|
+
test "can be rendered more than once" do
|
36
|
+
template = Tilt::RedcarpetTemplate.new { |t| "# Hello World!" }
|
37
|
+
3.times { assert_equal "<h1>Hello World!</h1>\n", template.render }
|
38
|
+
end
|
39
|
+
|
40
|
+
test "smartypants when :smart is set" do
|
41
|
+
template = Tilt::RedcarpetTemplate.new(:smart => true) { |t|
|
42
|
+
"OKAY -- 'Smarty Pants'" }
|
43
|
+
assert_equal "<p>OKAY — ‘Smarty Pants’</p>\n",
|
44
|
+
template.render
|
45
|
+
end
|
46
|
+
|
47
|
+
test "stripping HTML when :filter_html is set" do
|
48
|
+
template = Tilt::RedcarpetTemplate.new(:filter_html => true) { |t|
|
49
|
+
"HELLO <blink>WORLD</blink>" }
|
50
|
+
assert_equal "<p>HELLO <blink>WORLD</blink></p>\n", template.render
|
51
|
+
end
|
52
|
+
end
|
53
|
+
rescue LoadError => boom
|
54
|
+
warn "Tilt::RedcarpetTemplate (disabled)\n"
|
55
|
+
end
|
@@ -48,9 +48,9 @@ class StringTemplateTest < Test::Unit::TestCase
|
|
48
48
|
fail 'should have raised an exception'
|
49
49
|
rescue => boom
|
50
50
|
assert_kind_of NameError, boom
|
51
|
-
line = boom.backtrace.first
|
51
|
+
line = boom.backtrace.grep(/^test\.str:/).first
|
52
|
+
assert line, "Backtrace didn't contain test.str"
|
52
53
|
file, line, meth = line.split(":")
|
53
|
-
assert_equal 'test.str', file
|
54
54
|
assert_equal '13', line
|
55
55
|
end
|
56
56
|
end
|
@@ -119,6 +119,12 @@ class CompiledStringTemplateTest < Test::Unit::TestCase
|
|
119
119
|
assert_equal "Hello\nWorld!\n", template.render(Scope.new)
|
120
120
|
end
|
121
121
|
|
122
|
+
|
123
|
+
test "template with '}'" do
|
124
|
+
template = Tilt::StringTemplate.new { "Hello }" }
|
125
|
+
assert_equal "Hello }", template.render
|
126
|
+
end
|
127
|
+
|
122
128
|
test "backtrace file and line reporting without locals" do
|
123
129
|
data = File.read(__FILE__).split("\n__END__\n").last
|
124
130
|
fail unless data[0] == ?<
|
@@ -129,8 +135,9 @@ class CompiledStringTemplateTest < Test::Unit::TestCase
|
|
129
135
|
rescue => boom
|
130
136
|
assert_kind_of NameError, boom
|
131
137
|
line = boom.backtrace.first
|
138
|
+
line = boom.backtrace.grep(/^test\.str:/).first
|
139
|
+
assert line, "Backtrace didn't contain test.str"
|
132
140
|
file, line, meth = line.split(":")
|
133
|
-
assert_equal 'test.str', file
|
134
141
|
assert_equal '13', line
|
135
142
|
end
|
136
143
|
end
|
data/test/tilt_template_test.rb
CHANGED
@@ -121,6 +121,12 @@ class TiltTemplateTest < Test::Unit::TestCase
|
|
121
121
|
assert inst.prepared?
|
122
122
|
end
|
123
123
|
|
124
|
+
test "template_source with locals of strings" do
|
125
|
+
inst = SourceGeneratingMockTemplate.new { |t| 'Hey #{name}!' }
|
126
|
+
assert_equal "Hey Joe!", inst.render(Object.new, 'name' => 'Joe')
|
127
|
+
assert inst.prepared?
|
128
|
+
end
|
129
|
+
|
124
130
|
class Person
|
125
131
|
CONSTANT = "Bob"
|
126
132
|
|
data/tilt.gemspec
CHANGED
@@ -3,8 +3,8 @@ Gem::Specification.new do |s|
|
|
3
3
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
4
4
|
|
5
5
|
s.name = 'tilt'
|
6
|
-
s.version = '1.
|
7
|
-
s.date = '2011-
|
6
|
+
s.version = '1.3'
|
7
|
+
s.date = '2011-04-26'
|
8
8
|
|
9
9
|
s.description = "Generic interface to multiple Ruby template engines"
|
10
10
|
s.summary = s.description
|
@@ -20,6 +20,21 @@ Gem::Specification.new do |s|
|
|
20
20
|
TEMPLATES.md
|
21
21
|
bin/tilt
|
22
22
|
lib/tilt.rb
|
23
|
+
lib/tilt/builder.rb
|
24
|
+
lib/tilt/coffee.rb
|
25
|
+
lib/tilt/creole.rb
|
26
|
+
lib/tilt/css.rb
|
27
|
+
lib/tilt/erb.rb
|
28
|
+
lib/tilt/haml.rb
|
29
|
+
lib/tilt/liquid.rb
|
30
|
+
lib/tilt/markaby.rb
|
31
|
+
lib/tilt/markdown.rb
|
32
|
+
lib/tilt/nokogiri.rb
|
33
|
+
lib/tilt/radius.rb
|
34
|
+
lib/tilt/rdoc.rb
|
35
|
+
lib/tilt/string.rb
|
36
|
+
lib/tilt/template.rb
|
37
|
+
lib/tilt/textile.rb
|
23
38
|
test/contest.rb
|
24
39
|
test/markaby/locals.mab
|
25
40
|
test/markaby/markaby.mab
|
@@ -32,16 +47,22 @@ Gem::Specification.new do |s|
|
|
32
47
|
test/tilt_cache_test.rb
|
33
48
|
test/tilt_coffeescripttemplate_test.rb
|
34
49
|
test/tilt_compilesite_test.rb
|
50
|
+
test/tilt_creoletemplate_test.rb
|
35
51
|
test/tilt_erbtemplate_test.rb
|
36
52
|
test/tilt_erubistemplate_test.rb
|
53
|
+
test/tilt_fallback_test.rb
|
37
54
|
test/tilt_hamltemplate_test.rb
|
55
|
+
test/tilt_kramdown_test.rb
|
38
56
|
test/tilt_lesstemplate_test.rb
|
39
57
|
test/tilt_liquidtemplate_test.rb
|
40
58
|
test/tilt_markaby_test.rb
|
59
|
+
test/tilt_markdown_test.rb
|
60
|
+
test/tilt_marukutemplate_test.rb
|
41
61
|
test/tilt_nokogiritemplate_test.rb
|
42
62
|
test/tilt_radiustemplate_test.rb
|
43
63
|
test/tilt_rdiscounttemplate_test.rb
|
44
64
|
test/tilt_rdoctemplate_test.rb
|
65
|
+
test/tilt_redcarpettemplate_test.rb
|
45
66
|
test/tilt_redclothtemplate_test.rb
|
46
67
|
test/tilt_sasstemplate_test.rb
|
47
68
|
test/tilt_stringtemplate_test.rb
|
@@ -66,6 +87,11 @@ Gem::Specification.new do |s|
|
|
66
87
|
s.add_development_dependency 'nokogiri'
|
67
88
|
s.add_development_dependency 'markaby'
|
68
89
|
s.add_development_dependency 'coffee-script'
|
90
|
+
s.add_development_dependency 'bluecloth'
|
91
|
+
s.add_development_dependency 'RedCloth'
|
92
|
+
s.add_development_dependency 'maruku'
|
93
|
+
s.add_development_dependency 'creole'
|
94
|
+
s.add_development_dependency 'kramdown'
|
69
95
|
|
70
96
|
s.extra_rdoc_files = %w[COPYING]
|
71
97
|
|
metadata
CHANGED
@@ -1,12 +1,8 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tilt
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
prerelease:
|
5
|
-
|
6
|
-
- 1
|
7
|
-
- 2
|
8
|
-
- 2
|
9
|
-
version: 1.2.2
|
4
|
+
prerelease:
|
5
|
+
version: "1.3"
|
10
6
|
platform: ruby
|
11
7
|
authors:
|
12
8
|
- Ryan Tomayko
|
@@ -14,7 +10,7 @@ autorequire:
|
|
14
10
|
bindir: bin
|
15
11
|
cert_chain: []
|
16
12
|
|
17
|
-
date: 2011-
|
13
|
+
date: 2011-04-26 00:00:00 -07:00
|
18
14
|
default_executable: tilt
|
19
15
|
dependencies:
|
20
16
|
- !ruby/object:Gem::Dependency
|
@@ -25,8 +21,6 @@ dependencies:
|
|
25
21
|
requirements:
|
26
22
|
- - ">="
|
27
23
|
- !ruby/object:Gem::Version
|
28
|
-
segments:
|
29
|
-
- 0
|
30
24
|
version: "0"
|
31
25
|
type: :development
|
32
26
|
version_requirements: *id001
|
@@ -38,8 +32,6 @@ dependencies:
|
|
38
32
|
requirements:
|
39
33
|
- - ">="
|
40
34
|
- !ruby/object:Gem::Version
|
41
|
-
segments:
|
42
|
-
- 0
|
43
35
|
version: "0"
|
44
36
|
type: :development
|
45
37
|
version_requirements: *id002
|
@@ -51,8 +43,6 @@ dependencies:
|
|
51
43
|
requirements:
|
52
44
|
- - ">="
|
53
45
|
- !ruby/object:Gem::Version
|
54
|
-
segments:
|
55
|
-
- 0
|
56
46
|
version: "0"
|
57
47
|
type: :development
|
58
48
|
version_requirements: *id003
|
@@ -64,10 +54,6 @@ dependencies:
|
|
64
54
|
requirements:
|
65
55
|
- - ">="
|
66
56
|
- !ruby/object:Gem::Version
|
67
|
-
segments:
|
68
|
-
- 2
|
69
|
-
- 2
|
70
|
-
- 11
|
71
57
|
version: 2.2.11
|
72
58
|
type: :development
|
73
59
|
version_requirements: *id004
|
@@ -79,8 +65,6 @@ dependencies:
|
|
79
65
|
requirements:
|
80
66
|
- - ">="
|
81
67
|
- !ruby/object:Gem::Version
|
82
|
-
segments:
|
83
|
-
- 0
|
84
68
|
version: "0"
|
85
69
|
type: :development
|
86
70
|
version_requirements: *id005
|
@@ -92,8 +76,6 @@ dependencies:
|
|
92
76
|
requirements:
|
93
77
|
- - ">="
|
94
78
|
- !ruby/object:Gem::Version
|
95
|
-
segments:
|
96
|
-
- 0
|
97
79
|
version: "0"
|
98
80
|
type: :development
|
99
81
|
version_requirements: *id006
|
@@ -105,8 +87,6 @@ dependencies:
|
|
105
87
|
requirements:
|
106
88
|
- - ">="
|
107
89
|
- !ruby/object:Gem::Version
|
108
|
-
segments:
|
109
|
-
- 0
|
110
90
|
version: "0"
|
111
91
|
type: :development
|
112
92
|
version_requirements: *id007
|
@@ -118,8 +98,6 @@ dependencies:
|
|
118
98
|
requirements:
|
119
99
|
- - ">="
|
120
100
|
- !ruby/object:Gem::Version
|
121
|
-
segments:
|
122
|
-
- 0
|
123
101
|
version: "0"
|
124
102
|
type: :development
|
125
103
|
version_requirements: *id008
|
@@ -131,8 +109,6 @@ dependencies:
|
|
131
109
|
requirements:
|
132
110
|
- - ">="
|
133
111
|
- !ruby/object:Gem::Version
|
134
|
-
segments:
|
135
|
-
- 0
|
136
112
|
version: "0"
|
137
113
|
type: :development
|
138
114
|
version_requirements: *id009
|
@@ -144,8 +120,6 @@ dependencies:
|
|
144
120
|
requirements:
|
145
121
|
- - ">="
|
146
122
|
- !ruby/object:Gem::Version
|
147
|
-
segments:
|
148
|
-
- 0
|
149
123
|
version: "0"
|
150
124
|
type: :development
|
151
125
|
version_requirements: *id010
|
@@ -157,11 +131,64 @@ dependencies:
|
|
157
131
|
requirements:
|
158
132
|
- - ">="
|
159
133
|
- !ruby/object:Gem::Version
|
160
|
-
segments:
|
161
|
-
- 0
|
162
134
|
version: "0"
|
163
135
|
type: :development
|
164
136
|
version_requirements: *id011
|
137
|
+
- !ruby/object:Gem::Dependency
|
138
|
+
name: bluecloth
|
139
|
+
prerelease: false
|
140
|
+
requirement: &id012 !ruby/object:Gem::Requirement
|
141
|
+
none: false
|
142
|
+
requirements:
|
143
|
+
- - ">="
|
144
|
+
- !ruby/object:Gem::Version
|
145
|
+
version: "0"
|
146
|
+
type: :development
|
147
|
+
version_requirements: *id012
|
148
|
+
- !ruby/object:Gem::Dependency
|
149
|
+
name: RedCloth
|
150
|
+
prerelease: false
|
151
|
+
requirement: &id013 !ruby/object:Gem::Requirement
|
152
|
+
none: false
|
153
|
+
requirements:
|
154
|
+
- - ">="
|
155
|
+
- !ruby/object:Gem::Version
|
156
|
+
version: "0"
|
157
|
+
type: :development
|
158
|
+
version_requirements: *id013
|
159
|
+
- !ruby/object:Gem::Dependency
|
160
|
+
name: maruku
|
161
|
+
prerelease: false
|
162
|
+
requirement: &id014 !ruby/object:Gem::Requirement
|
163
|
+
none: false
|
164
|
+
requirements:
|
165
|
+
- - ">="
|
166
|
+
- !ruby/object:Gem::Version
|
167
|
+
version: "0"
|
168
|
+
type: :development
|
169
|
+
version_requirements: *id014
|
170
|
+
- !ruby/object:Gem::Dependency
|
171
|
+
name: creole
|
172
|
+
prerelease: false
|
173
|
+
requirement: &id015 !ruby/object:Gem::Requirement
|
174
|
+
none: false
|
175
|
+
requirements:
|
176
|
+
- - ">="
|
177
|
+
- !ruby/object:Gem::Version
|
178
|
+
version: "0"
|
179
|
+
type: :development
|
180
|
+
version_requirements: *id015
|
181
|
+
- !ruby/object:Gem::Dependency
|
182
|
+
name: kramdown
|
183
|
+
prerelease: false
|
184
|
+
requirement: &id016 !ruby/object:Gem::Requirement
|
185
|
+
none: false
|
186
|
+
requirements:
|
187
|
+
- - ">="
|
188
|
+
- !ruby/object:Gem::Version
|
189
|
+
version: "0"
|
190
|
+
type: :development
|
191
|
+
version_requirements: *id016
|
165
192
|
description: Generic interface to multiple Ruby template engines
|
166
193
|
email: r@tomayko.com
|
167
194
|
executables:
|
@@ -177,6 +204,21 @@ files:
|
|
177
204
|
- TEMPLATES.md
|
178
205
|
- bin/tilt
|
179
206
|
- lib/tilt.rb
|
207
|
+
- lib/tilt/builder.rb
|
208
|
+
- lib/tilt/coffee.rb
|
209
|
+
- lib/tilt/creole.rb
|
210
|
+
- lib/tilt/css.rb
|
211
|
+
- lib/tilt/erb.rb
|
212
|
+
- lib/tilt/haml.rb
|
213
|
+
- lib/tilt/liquid.rb
|
214
|
+
- lib/tilt/markaby.rb
|
215
|
+
- lib/tilt/markdown.rb
|
216
|
+
- lib/tilt/nokogiri.rb
|
217
|
+
- lib/tilt/radius.rb
|
218
|
+
- lib/tilt/rdoc.rb
|
219
|
+
- lib/tilt/string.rb
|
220
|
+
- lib/tilt/template.rb
|
221
|
+
- lib/tilt/textile.rb
|
180
222
|
- test/contest.rb
|
181
223
|
- test/markaby/locals.mab
|
182
224
|
- test/markaby/markaby.mab
|
@@ -189,16 +231,22 @@ files:
|
|
189
231
|
- test/tilt_cache_test.rb
|
190
232
|
- test/tilt_coffeescripttemplate_test.rb
|
191
233
|
- test/tilt_compilesite_test.rb
|
234
|
+
- test/tilt_creoletemplate_test.rb
|
192
235
|
- test/tilt_erbtemplate_test.rb
|
193
236
|
- test/tilt_erubistemplate_test.rb
|
237
|
+
- test/tilt_fallback_test.rb
|
194
238
|
- test/tilt_hamltemplate_test.rb
|
239
|
+
- test/tilt_kramdown_test.rb
|
195
240
|
- test/tilt_lesstemplate_test.rb
|
196
241
|
- test/tilt_liquidtemplate_test.rb
|
197
242
|
- test/tilt_markaby_test.rb
|
243
|
+
- test/tilt_markdown_test.rb
|
244
|
+
- test/tilt_marukutemplate_test.rb
|
198
245
|
- test/tilt_nokogiritemplate_test.rb
|
199
246
|
- test/tilt_radiustemplate_test.rb
|
200
247
|
- test/tilt_rdiscounttemplate_test.rb
|
201
248
|
- test/tilt_rdoctemplate_test.rb
|
249
|
+
- test/tilt_redcarpettemplate_test.rb
|
202
250
|
- test/tilt_redclothtemplate_test.rb
|
203
251
|
- test/tilt_sasstemplate_test.rb
|
204
252
|
- test/tilt_stringtemplate_test.rb
|
@@ -224,21 +272,17 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
224
272
|
requirements:
|
225
273
|
- - ">="
|
226
274
|
- !ruby/object:Gem::Version
|
227
|
-
segments:
|
228
|
-
- 0
|
229
275
|
version: "0"
|
230
276
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
231
277
|
none: false
|
232
278
|
requirements:
|
233
279
|
- - ">="
|
234
280
|
- !ruby/object:Gem::Version
|
235
|
-
segments:
|
236
|
-
- 0
|
237
281
|
version: "0"
|
238
282
|
requirements: []
|
239
283
|
|
240
284
|
rubyforge_project: wink
|
241
|
-
rubygems_version: 1.
|
285
|
+
rubygems_version: 1.6.0
|
242
286
|
signing_key:
|
243
287
|
specification_version: 2
|
244
288
|
summary: Generic interface to multiple Ruby template engines
|
@@ -248,16 +292,22 @@ test_files:
|
|
248
292
|
- test/tilt_cache_test.rb
|
249
293
|
- test/tilt_coffeescripttemplate_test.rb
|
250
294
|
- test/tilt_compilesite_test.rb
|
295
|
+
- test/tilt_creoletemplate_test.rb
|
251
296
|
- test/tilt_erbtemplate_test.rb
|
252
297
|
- test/tilt_erubistemplate_test.rb
|
298
|
+
- test/tilt_fallback_test.rb
|
253
299
|
- test/tilt_hamltemplate_test.rb
|
300
|
+
- test/tilt_kramdown_test.rb
|
254
301
|
- test/tilt_lesstemplate_test.rb
|
255
302
|
- test/tilt_liquidtemplate_test.rb
|
256
303
|
- test/tilt_markaby_test.rb
|
304
|
+
- test/tilt_markdown_test.rb
|
305
|
+
- test/tilt_marukutemplate_test.rb
|
257
306
|
- test/tilt_nokogiritemplate_test.rb
|
258
307
|
- test/tilt_radiustemplate_test.rb
|
259
308
|
- test/tilt_rdiscounttemplate_test.rb
|
260
309
|
- test/tilt_rdoctemplate_test.rb
|
310
|
+
- test/tilt_redcarpettemplate_test.rb
|
261
311
|
- test/tilt_redclothtemplate_test.rb
|
262
312
|
- test/tilt_sasstemplate_test.rb
|
263
313
|
- test/tilt_stringtemplate_test.rb
|