webby 0.8.4 → 0.9.0
Sign up to get free protection for your applications and to get access to all the features.
- data/History.txt +19 -0
- data/Manifest.txt +104 -91
- data/README.txt +27 -45
- data/Rakefile +4 -5
- data/bin/webby +2 -1
- data/bin/webby-gen +8 -0
- data/{data/Rakefile → examples/blog/Sitefile} +0 -2
- data/examples/{webby → blog}/tasks/blog.rake +5 -4
- data/{data → examples/blog}/templates/atom_feed.erb +10 -11
- data/{data → examples/blog}/templates/blog/month.erb +1 -1
- data/{data → examples/blog}/templates/blog/post.erb +1 -0
- data/{data → examples/blog}/templates/blog/year.erb +1 -1
- data/examples/presentation/{Rakefile → Sitefile} +0 -4
- data/examples/presentation/content/{_sample_code.txt → presentation/_sample_code.txt} +0 -0
- data/examples/presentation/content/{index.txt → presentation/index.txt} +0 -0
- data/{data/content → examples/presentation/content/presentation}/s5/blank.gif +0 -0
- data/{data/content → examples/presentation/content/presentation}/s5/bodybg.gif +0 -0
- data/{data/content → examples/presentation/content/presentation}/s5/framing.css +0 -0
- data/{data/content → examples/presentation/content/presentation}/s5/iepngfix.htc +0 -0
- data/{data/content → examples/presentation/content/presentation}/s5/opera.css +0 -0
- data/{data/content → examples/presentation/content/presentation}/s5/outline.css +0 -0
- data/{data/content → examples/presentation/content/presentation}/s5/pretty.css +0 -0
- data/{data/content → examples/presentation/content/presentation}/s5/print.css +0 -0
- data/{data/content → examples/presentation/content/presentation}/s5/s5-core.css +0 -0
- data/{data/content → examples/presentation/content/presentation}/s5/slides.css +0 -0
- data/{data/content → examples/presentation/content/presentation}/s5/slides.js +0 -0
- data/examples/presentation/layouts/{presentation.rhtml → presentation.txt} +3 -3
- data/examples/presentation/templates/{_partial.erb → _code_partial.erb} +0 -0
- data/examples/tumblog/Sitefile +9 -0
- data/examples/tumblog/content/css/tumblog.css +308 -0
- data/examples/tumblog/content/images/tumblog/permalink.gif +0 -0
- data/examples/tumblog/content/images/tumblog/rss.gif +0 -0
- data/examples/tumblog/content/tumblog/200806/the-noble-chicken/index.txt +12 -0
- data/examples/tumblog/content/tumblog/200807/historical-perspectives-on-the-classic-chicken-joke/index.txt +12 -0
- data/examples/tumblog/content/tumblog/200807/mad-city-chickens/index.txt +10 -0
- data/examples/tumblog/content/tumblog/200807/the-wisdom-of-the-dutch/index.txt +11 -0
- data/examples/tumblog/content/tumblog/200807/up-a-tree/index.txt +13 -0
- data/examples/tumblog/content/tumblog/index.txt +37 -0
- data/examples/tumblog/content/tumblog/rss.txt +37 -0
- data/examples/tumblog/layouts/tumblog/default.txt +44 -0
- data/examples/tumblog/layouts/tumblog/post.txt +15 -0
- data/examples/tumblog/lib/tumblog_helper.rb +32 -0
- data/examples/tumblog/tasks/tumblog.rake +30 -0
- data/examples/tumblog/templates/atom_feed.erb +40 -0
- data/examples/tumblog/templates/tumblog/conversation.erb +12 -0
- data/examples/tumblog/templates/tumblog/link.erb +10 -0
- data/examples/tumblog/templates/tumblog/photo.erb +13 -0
- data/examples/tumblog/templates/tumblog/post.erb +12 -0
- data/examples/tumblog/templates/tumblog/quote.erb +11 -0
- data/examples/webby/{Rakefile → Sitefile} +2 -2
- data/examples/webby/content/communicate/index.txt +28 -0
- data/examples/webby/content/css/background.gif +0 -0
- data/examples/webby/content/css/site.css +52 -20
- data/examples/webby/content/index.txt +7 -8
- data/examples/webby/content/learn/index.txt +28 -0
- data/examples/webby/content/reference/index.txt +3 -1
- data/examples/webby/content/release-notes/rel-0-9-0/index.txt +73 -0
- data/examples/webby/content/sitemap.txt +31 -0
- data/examples/webby/content/tips_and_tricks/index.txt +1 -1
- data/examples/webby/content/tutorial/index.txt +17 -17
- data/examples/webby/content/{manual → user-manual}/index.txt +53 -50
- data/examples/webby/layouts/{default.rhtml → default.txt} +8 -15
- data/examples/webby/templates/page.erb +1 -1
- data/examples/website/Sitefile +7 -0
- data/{data → examples/website}/content/css/blueprint/License.txt +0 -0
- data/{data → examples/website}/content/css/blueprint/Readme.txt +0 -0
- data/{data → examples/website}/content/css/blueprint/compressed/print.css +0 -0
- data/{data → examples/website}/content/css/blueprint/compressed/screen.css +0 -0
- data/{data → examples/website}/content/css/blueprint/lib/forms.css +0 -0
- data/{data → examples/website}/content/css/blueprint/lib/grid.css +0 -0
- data/{data → examples/website}/content/css/blueprint/lib/grid.png +0 -0
- data/{data → examples/website}/content/css/blueprint/lib/ie.css +0 -0
- data/{data → examples/website}/content/css/blueprint/lib/reset.css +0 -0
- data/{data → examples/website}/content/css/blueprint/lib/typography.css +0 -0
- data/{data → examples/website}/content/css/blueprint/plugins/buttons/Readme +0 -0
- data/{data → examples/website}/content/css/blueprint/plugins/buttons/buttons.css +0 -0
- data/{data → examples/website}/content/css/blueprint/plugins/buttons/icons/cross.png +0 -0
- data/{data → examples/website}/content/css/blueprint/plugins/buttons/icons/key.png +0 -0
- data/{data → examples/website}/content/css/blueprint/plugins/buttons/icons/tick.png +0 -0
- data/{data → examples/website}/content/css/blueprint/plugins/css-classes/Readme +0 -0
- data/{data → examples/website}/content/css/blueprint/plugins/css-classes/css-classes.css +0 -0
- data/{data → examples/website}/content/css/blueprint/plugins/fancy-type/Readme +0 -0
- data/{data → examples/website}/content/css/blueprint/plugins/fancy-type/fancy-type-compressed.css +0 -0
- data/{data → examples/website}/content/css/blueprint/plugins/fancy-type/fancy-type.css +0 -0
- data/{data → examples/website}/content/css/blueprint/print.css +0 -0
- data/{data → examples/website}/content/css/blueprint/screen.css +0 -0
- data/{data → examples/website}/content/css/coderay.css +0 -0
- data/{data → examples/website}/content/css/site.css +0 -0
- data/{data → examples/website}/content/index.txt +2 -1
- data/{data/layouts/default.rhtml → examples/website/layouts/default.txt} +1 -1
- data/{data → examples/website}/lib/breadcrumbs.rb +0 -0
- data/{data → examples/website}/templates/_partial.erb +0 -0
- data/{data → examples/website}/templates/page.erb +0 -0
- data/{data → examples/website}/templates/presentation.erb +0 -0
- data/lib/webby/apps/generator.rb +283 -0
- data/lib/webby/apps/main.rb +221 -0
- data/lib/webby/apps.rb +12 -0
- data/lib/webby/builder.rb +8 -10
- data/lib/webby/core_ext/enumerable.rb +11 -0
- data/lib/webby/{utils.rb → core_ext/hash.rb} +2 -26
- data/lib/webby/core_ext/kernel.rb +21 -0
- data/lib/webby/core_ext/string.rb +163 -0
- data/lib/webby/core_ext/time.rb +9 -0
- data/lib/webby/filters/haml.rb +13 -5
- data/lib/webby/filters/markdown.rb +12 -4
- data/lib/webby/filters/outline.rb +3 -2
- data/lib/webby/filters/sass.rb +12 -4
- data/lib/webby/filters/textile.rb +12 -4
- data/lib/webby/filters/tidy.rb +10 -8
- data/lib/webby/filters.rb +2 -0
- data/lib/webby/helpers/graphviz_helper.rb +1 -2
- data/lib/webby/helpers/tex_img_helper.rb +6 -10
- data/lib/webby/renderer.rb +5 -3
- data/lib/webby/resources/layout.rb +1 -1
- data/lib/webby/resources/page.rb +1 -1
- data/lib/webby/resources/resource.rb +13 -3
- data/lib/webby/resources.rb +16 -0
- data/{data → lib/webby}/tasks/build.rake +0 -0
- data/{examples/presentation → lib/webby}/tasks/create.rake +1 -1
- data/{data → lib/webby}/tasks/deploy.rake +0 -0
- data/{examples → lib}/webby/tasks/growl.rake +4 -1
- data/{data → lib/webby}/tasks/heel.rake +0 -0
- data/{data → lib/webby}/tasks/validate.rake +0 -0
- data/lib/webby.rb +11 -5
- data/spec/core_ext/hash_spec.rb +47 -0
- data/spec/core_ext/string_spec.rb +110 -0
- data/spec/core_ext/time_spec.rb +19 -0
- data/spec/webby/apps/generator_spec.rb +111 -0
- data/spec/webby/apps/main_spec.rb +75 -0
- data/spec/webby/helpers/capture_helper_spec.rb +1 -1
- data/spec/webby/resources_spec.rb +17 -0
- data/tasks/gem.rake +10 -2
- data/tasks/git.rake +41 -0
- data/tasks/rubyforge.rake +2 -2
- data/tasks/website.rake +38 -38
- metadata +125 -98
- data/data/tasks/blog.rake +0 -71
- data/data/tasks/create.rake +0 -22
- data/data/tasks/growl.rake +0 -12
- data/data/tasks/setup.rb +0 -17
- data/examples/presentation/content/s5/blank.gif +0 -0
- data/examples/presentation/content/s5/bodybg.gif +0 -0
- data/examples/presentation/content/s5/framing.css +0 -23
- data/examples/presentation/content/s5/iepngfix.htc +0 -42
- data/examples/presentation/content/s5/opera.css +0 -7
- data/examples/presentation/content/s5/outline.css +0 -15
- data/examples/presentation/content/s5/pretty.css +0 -86
- data/examples/presentation/content/s5/print.css +0 -1
- data/examples/presentation/content/s5/s5-core.css +0 -9
- data/examples/presentation/content/s5/slides.css +0 -3
- data/examples/presentation/content/s5/slides.js +0 -553
- data/examples/presentation/tasks/blog.rake +0 -71
- data/examples/presentation/tasks/build.rake +0 -27
- data/examples/presentation/tasks/deploy.rake +0 -22
- data/examples/presentation/tasks/growl.rake +0 -12
- data/examples/presentation/tasks/heel.rake +0 -28
- data/examples/presentation/tasks/setup.rb +0 -17
- data/examples/presentation/tasks/validate.rake +0 -19
- data/examples/webby/tasks/build.rake +0 -27
- data/examples/webby/tasks/create.rake +0 -22
- data/examples/webby/tasks/deploy.rake +0 -22
- data/examples/webby/tasks/heel.rake +0 -28
- data/examples/webby/tasks/setup.rb +0 -17
- data/examples/webby/tasks/validate.rake +0 -19
- data/lib/webby/main.rb +0 -227
@@ -0,0 +1,308 @@
|
|
1
|
+
---
|
2
|
+
extension: css
|
3
|
+
filter: sass
|
4
|
+
layout: nil # no layout
|
5
|
+
sass_options:
|
6
|
+
:style: :expanded
|
7
|
+
---
|
8
|
+
!background = #FFF
|
9
|
+
!text = #000
|
10
|
+
!border = #CCC
|
11
|
+
!header = #6498CC
|
12
|
+
!link = #6498CC
|
13
|
+
!link_hover = #000
|
14
|
+
!blockquote = #666
|
15
|
+
!code = #000
|
16
|
+
!box_bg = #EEE
|
17
|
+
!highlight = #6498CC
|
18
|
+
!quiet = #666
|
19
|
+
!alt = #666
|
20
|
+
|
21
|
+
!title = #444
|
22
|
+
!description = #777
|
23
|
+
!date = #CCC
|
24
|
+
!date_brick = #BBD5F1
|
25
|
+
|
26
|
+
body
|
27
|
+
:margin 0px
|
28
|
+
:background-color = !background
|
29
|
+
:font-family Verdana, Geneva, Arial, sans-serif
|
30
|
+
|
31
|
+
a
|
32
|
+
:color = !link
|
33
|
+
:text-decoration none
|
34
|
+
&:hover
|
35
|
+
:text-decoration underline
|
36
|
+
|
37
|
+
h1
|
38
|
+
:width 600px
|
39
|
+
:padding 0px 100px 20px 100px
|
40
|
+
:margin 50px auto 40px auto
|
41
|
+
:border-bottom = solid 1px !border
|
42
|
+
:text-align center
|
43
|
+
:font Bold 55px 'Trebuchet MS', Geneva, Arial, sans-serif
|
44
|
+
:letter-spacing -2px
|
45
|
+
:line-height 50px
|
46
|
+
:position relative
|
47
|
+
|
48
|
+
a
|
49
|
+
:color = !title
|
50
|
+
:text-decoration none
|
51
|
+
&:hover
|
52
|
+
:text-decoration none
|
53
|
+
|
54
|
+
img
|
55
|
+
:border-width 0px
|
56
|
+
:position absolute
|
57
|
+
:right 0px
|
58
|
+
:bottom 10px
|
59
|
+
:width 43px
|
60
|
+
:height 23px
|
61
|
+
|
62
|
+
|
63
|
+
div#content
|
64
|
+
:width 420px
|
65
|
+
:margin auto
|
66
|
+
:position relative
|
67
|
+
|
68
|
+
div#description
|
69
|
+
:position absolute
|
70
|
+
:right -170px
|
71
|
+
:width 160px
|
72
|
+
:text-align right
|
73
|
+
:font Normal 17px Verdana, Geneva, Arial, sans-serif
|
74
|
+
:line-height 20px
|
75
|
+
:color = !description
|
76
|
+
|
77
|
+
a
|
78
|
+
:color = !description
|
79
|
+
:text-decoration underline
|
80
|
+
|
81
|
+
div.post
|
82
|
+
:position relative
|
83
|
+
:margin-bottom 40px
|
84
|
+
:padding-right 20px
|
85
|
+
|
86
|
+
div.date
|
87
|
+
:position absolute
|
88
|
+
:left -260px
|
89
|
+
:text-align right
|
90
|
+
:width 230px
|
91
|
+
:white-space nowrap
|
92
|
+
:font Normal 34px Verdana, Geneva, Arial, sans-serif
|
93
|
+
:letter-spacing -2px
|
94
|
+
:color = !date
|
95
|
+
:text-transform uppercase
|
96
|
+
:line-height 35px
|
97
|
+
|
98
|
+
div.date_brick
|
99
|
+
:float right
|
100
|
+
:height 30px
|
101
|
+
:width 45px
|
102
|
+
:background-color = !highlight
|
103
|
+
:color = !date_brick
|
104
|
+
:font Bold 12px Verdana, Geneva, Arial, sans-serif
|
105
|
+
:text-align center
|
106
|
+
:line-height 12px
|
107
|
+
:margin-left 10px
|
108
|
+
:padding-top 5px
|
109
|
+
:letter-spacing 0px
|
110
|
+
:overflow hidden
|
111
|
+
|
112
|
+
img.permalink
|
113
|
+
:width 14px
|
114
|
+
:height 13px
|
115
|
+
:border-width 0px
|
116
|
+
:background-color #000
|
117
|
+
:display none
|
118
|
+
:position absolute
|
119
|
+
:right 0px
|
120
|
+
:top 0px
|
121
|
+
:z-index 10
|
122
|
+
|
123
|
+
&:hover
|
124
|
+
img.permalink
|
125
|
+
:display inline
|
126
|
+
|
127
|
+
h2
|
128
|
+
:font Bold 18px 'Trebuchet MS', Geneva, Arial, sans-serif
|
129
|
+
:color #6498CC
|
130
|
+
:letter-spacing -1px
|
131
|
+
:margin 0px 0px 5px 0px
|
132
|
+
|
133
|
+
a
|
134
|
+
:color #6498CC
|
135
|
+
:text-decoration none
|
136
|
+
|
137
|
+
div.caption
|
138
|
+
:font-size 14px
|
139
|
+
:font-weight bold
|
140
|
+
:color #444
|
141
|
+
:margin-top 10px
|
142
|
+
:padding 0px 20px 0px 20px
|
143
|
+
|
144
|
+
a
|
145
|
+
:color #444
|
146
|
+
|
147
|
+
// Regular Post
|
148
|
+
|
149
|
+
div.regular
|
150
|
+
:font-size 12px
|
151
|
+
:color #444
|
152
|
+
:line-height 17px
|
153
|
+
|
154
|
+
h2
|
155
|
+
:font-size 36px
|
156
|
+
:line-height 34px
|
157
|
+
|
158
|
+
blockquote
|
159
|
+
:font-style italic
|
160
|
+
:border-left solid 2px #444
|
161
|
+
:padding-left 10px
|
162
|
+
|
163
|
+
// Quote Post
|
164
|
+
|
165
|
+
div.quote
|
166
|
+
h2
|
167
|
+
:font-size 36px
|
168
|
+
:line-height 34px
|
169
|
+
a
|
170
|
+
:color #6498CC
|
171
|
+
|
172
|
+
p
|
173
|
+
:font Bold 28px Helvetica, sans-serif
|
174
|
+
:letter-spacing -1px
|
175
|
+
:color #666
|
176
|
+
|
177
|
+
a
|
178
|
+
:color #666
|
179
|
+
|
180
|
+
big
|
181
|
+
:font Bold 60px Georgia, serif
|
182
|
+
:line-height 8px
|
183
|
+
:vertical-align -20px
|
184
|
+
|
185
|
+
span.source
|
186
|
+
:font Bold 16px Verdana, Geneva, Arial, sans-serif
|
187
|
+
:color #444
|
188
|
+
:letter-spacing -1px
|
189
|
+
|
190
|
+
a
|
191
|
+
:color #444
|
192
|
+
|
193
|
+
div.source
|
194
|
+
:font-size 16px
|
195
|
+
:font-weight Bold
|
196
|
+
:color #555
|
197
|
+
:margin-top 5px
|
198
|
+
|
199
|
+
a
|
200
|
+
:color #555
|
201
|
+
|
202
|
+
// Link Post
|
203
|
+
|
204
|
+
div.link
|
205
|
+
h2
|
206
|
+
:font-size 36px
|
207
|
+
:line-height 34px
|
208
|
+
|
209
|
+
a.link
|
210
|
+
:font Bold 20px Verdana, Geneva, Arial, sans-serif
|
211
|
+
:letter-spacing -1px
|
212
|
+
:color #C00
|
213
|
+
|
214
|
+
span.description
|
215
|
+
:font-size 13px
|
216
|
+
:font-weight normal
|
217
|
+
:letter-spacing -1px
|
218
|
+
:color #444
|
219
|
+
|
220
|
+
// Conversation Post
|
221
|
+
|
222
|
+
div.conversation
|
223
|
+
ul
|
224
|
+
:list-style-type none
|
225
|
+
:margin 0px
|
226
|
+
:padding 0px 0px 0px 1px
|
227
|
+
|
228
|
+
li
|
229
|
+
:font-size 12px
|
230
|
+
:padding 4px 10px 4px 8px
|
231
|
+
:color #444
|
232
|
+
:margin-bottom 1px
|
233
|
+
|
234
|
+
span.label
|
235
|
+
:font-weight bold
|
236
|
+
|
237
|
+
span.user_1
|
238
|
+
:color #C00
|
239
|
+
|
240
|
+
span.user_2
|
241
|
+
:color #00C
|
242
|
+
|
243
|
+
span.user_3
|
244
|
+
:color #0A0
|
245
|
+
|
246
|
+
li.odd
|
247
|
+
:background-color #F4F4F4
|
248
|
+
|
249
|
+
li.even
|
250
|
+
:background-color #E8E8E8
|
251
|
+
|
252
|
+
h2
|
253
|
+
:font-size 36px
|
254
|
+
:line-height 34px
|
255
|
+
:position relative
|
256
|
+
:top -4px
|
257
|
+
:margin-top 0px
|
258
|
+
:padding-top 0px
|
259
|
+
|
260
|
+
// Photo Post
|
261
|
+
|
262
|
+
div.photo
|
263
|
+
h2
|
264
|
+
:font-size 36px
|
265
|
+
:line-height 34px
|
266
|
+
|
267
|
+
p.caption
|
268
|
+
:font-size 11px
|
269
|
+
:color #444
|
270
|
+
:margin-top 5px
|
271
|
+
a
|
272
|
+
:color #444
|
273
|
+
|
274
|
+
// Video Post
|
275
|
+
|
276
|
+
div.video
|
277
|
+
:width 400px
|
278
|
+
:margin auto
|
279
|
+
|
280
|
+
h2
|
281
|
+
:font-size 36px
|
282
|
+
:line-height 40px
|
283
|
+
:letter-spacing -1px
|
284
|
+
:font-weight Bold
|
285
|
+
:font-family 'Trebuchet MS', Geneva, Arial, sans-serif
|
286
|
+
:margin 0px 0px 5px 0px
|
287
|
+
|
288
|
+
// Footer
|
289
|
+
|
290
|
+
div#footer
|
291
|
+
:margin 40px 0px 30px 0px
|
292
|
+
:text-align center
|
293
|
+
:font-size 15px
|
294
|
+
:font-weight bold
|
295
|
+
:color #444
|
296
|
+
|
297
|
+
a
|
298
|
+
:text-decoration none
|
299
|
+
:color #444
|
300
|
+
|
301
|
+
&:hover
|
302
|
+
:text-decoration underline
|
303
|
+
|
304
|
+
div#credit
|
305
|
+
:font Normal 13px Verdana, Geneva, Arial, sans-serif
|
306
|
+
:margin-top 15px
|
307
|
+
|
308
|
+
// EOF
|
Binary file
|
Binary file
|
@@ -0,0 +1,12 @@
|
|
1
|
+
---
|
2
|
+
title: The Noble Chicken
|
3
|
+
created_at: 2008-06-26 16:09:15.185670 -06:00
|
4
|
+
author: Tim Pease
|
5
|
+
filter:
|
6
|
+
- textile
|
7
|
+
layout: tumblog/post
|
8
|
+
tumblog_type: regular
|
9
|
+
---
|
10
|
+
The *chicken* (_Gallus gallus_, sometimes _G. gallus domesticus_) is a domesticated fowl likely descended from the wild Indian and southeast Asian Red Junglefowl (_Gallus gallus_) and the related Grey Junglefowl (_G. sonneratii_). Traditionally it has been widely accepted that the chicken was descended solely from the former, as hybrids of both wild types tended toward sterility; but recent genetic work has revealed that the genotype for yellow skin present in the domestic fowl is not present in what is otherwise its closest kin, the Red Junglefowl. It is deemed most likely, then, that the yellow skin trait in domestic birds originated in the Grey Junglefowl.
|
11
|
+
|
12
|
+
The chicken is one of the most common and widespread domestic animals. With a population of more than 24 billion in 2003, there are more chickens in the world than any other bird. Humans keep chickens primarily as a source of food, with both their meat and their eggs consumed.
|
@@ -0,0 +1,12 @@
|
|
1
|
+
---
|
2
|
+
title: Historical Perspectives on the Classic Chicken Joke
|
3
|
+
created_at: 2008-07-16 16:10:35.789008 -06:00
|
4
|
+
author: Tim Pease
|
5
|
+
filter:
|
6
|
+
- textile
|
7
|
+
layout: tumblog/post
|
8
|
+
tumblog_type: conversation
|
9
|
+
---
|
10
|
+
* %(label)me :% Why did the chicken cross the road?
|
11
|
+
* %(label)Buddha :% If you ask this question, you deny your own chicken nature.
|
12
|
+
* %(label)Darwin :% Chickens, over great periods of time, have been naturally selected in such a way that they are now genetically predisposed to cross roads.
|
@@ -0,0 +1,11 @@
|
|
1
|
+
---
|
2
|
+
title: The Wisdom of the Dutch
|
3
|
+
created_at: 2008-07-26 16:11:39.658919 -06:00
|
4
|
+
author: Tim Pease
|
5
|
+
filter:
|
6
|
+
- textile
|
7
|
+
layout: tumblog/post
|
8
|
+
tumblog_type: quote
|
9
|
+
---
|
10
|
+
<big>“</big> You can't hatch chickens from fried eggs.
|
11
|
+
%(source)Dutch Proverb%
|
@@ -0,0 +1,13 @@
|
|
1
|
+
---
|
2
|
+
title: Up a Tree
|
3
|
+
created_at: 2008-07-06 16:09:49.530410 -06:00
|
4
|
+
author: Tim Pease
|
5
|
+
filter:
|
6
|
+
- erb
|
7
|
+
- textile
|
8
|
+
layout: tumblog/post
|
9
|
+
tumblog_type: photo
|
10
|
+
---
|
11
|
+
!http://www.madcitychickens.com/images/bttrcups_tree.jpg(<%= h(@page.title) %>)!
|
12
|
+
|
13
|
+
p(caption). via "Mad City Chickens":http://www.madcitychickens.com/
|
@@ -0,0 +1,37 @@
|
|
1
|
+
---
|
2
|
+
title: A Mother Clucker
|
3
|
+
author: Tim Pease
|
4
|
+
layout: tumblog/default
|
5
|
+
filter: erb
|
6
|
+
dirty: true
|
7
|
+
---
|
8
|
+
<% prev = nil
|
9
|
+
posts = @pages.find(
|
10
|
+
:all,
|
11
|
+
:layout => 'tumblog/post',
|
12
|
+
:sort_by => :created_at,
|
13
|
+
:reverse => true
|
14
|
+
)
|
15
|
+
paginate(posts, 4) do |p| -%>
|
16
|
+
<div class="post">
|
17
|
+
<% if prev != p.created_at.strftime('%Y%m%d') -%>
|
18
|
+
<%= tumblog_date(p.created_at) %>
|
19
|
+
<% prev = p.created_at.strftime('%Y%m%d')
|
20
|
+
end -%>
|
21
|
+
<a href="<%= p.url %>">
|
22
|
+
<img src="/images/tumblog/permalink.gif" class="permalink" alt="permalink" />
|
23
|
+
</a>
|
24
|
+
|
25
|
+
<div class="<%= p.tumblog_type %>">
|
26
|
+
<% if p.title -%>
|
27
|
+
<h2><%= link_to_page(p) %></h2>
|
28
|
+
<% end -%>
|
29
|
+
<%= render(p) %>
|
30
|
+
</div>
|
31
|
+
</div>
|
32
|
+
<% end -%>
|
33
|
+
|
34
|
+
<% content_for :footer do -%>
|
35
|
+
<%= link_to("« Prev", @pager.prev) if @pager.prev? %>
|
36
|
+
<%= link_to("Next »", @pager.next) if @pager.next? %>
|
37
|
+
<% end -%>
|
@@ -0,0 +1,37 @@
|
|
1
|
+
---
|
2
|
+
title: A Mother Clucker
|
3
|
+
subtitle: raising chickens in the city
|
4
|
+
site: example.com
|
5
|
+
author: Tim Pease
|
6
|
+
email: author@example.com
|
7
|
+
extension: xml
|
8
|
+
layout: nil
|
9
|
+
dirty: true
|
10
|
+
filter: erb
|
11
|
+
---
|
12
|
+
<?xml version="1.0" encoding="utf-8"?>
|
13
|
+
<feed xmlns="http://www.w3.org/2005/Atom">
|
14
|
+
|
15
|
+
<title><%= h(@page.title) %></title>
|
16
|
+
<subtitle><%= h(@page.subtitle) %></subtitle>
|
17
|
+
<link href="http://<%= @page.site %>/tumblog/" rel="self" />
|
18
|
+
<link href="http://<%= @page.site %>/" />
|
19
|
+
<updated><%= Time.now.xmlschema %></updated>
|
20
|
+
<author>
|
21
|
+
<name><%= h(@page.author) %></name>
|
22
|
+
<email><%= h(@page.email) %></email>
|
23
|
+
</author>
|
24
|
+
<id>http://<%= @page.site %>/</id>
|
25
|
+
<% @pages.find(:limit => 10,
|
26
|
+
:layout => 'tumblog/post',
|
27
|
+
:sort_by => 'created_at',
|
28
|
+
:reverse => true).each do |article| %>
|
29
|
+
<entry>
|
30
|
+
<title><%= h(article.title) %></title>
|
31
|
+
<link href="<%= article.url %>" />
|
32
|
+
<id>tag:<%= @page.site %>,<%= article.created_at.strftime('%Y-%m-%d') %>:<%= article.created_at.to_i %></id>
|
33
|
+
<updated><%= article.created_at.xmlschema %></updated>
|
34
|
+
<content type="html"><%= h(render(article)) %></content>
|
35
|
+
</entry>
|
36
|
+
<% end %>
|
37
|
+
</feed>
|
@@ -0,0 +1,44 @@
|
|
1
|
+
---
|
2
|
+
extension: html
|
3
|
+
filter: erb
|
4
|
+
---
|
5
|
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
6
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
7
|
+
|
8
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en-us">
|
9
|
+
<head>
|
10
|
+
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
11
|
+
<title><%= h(@page.title) %></title>
|
12
|
+
<meta name="author" content="<%= h(@page.author) %>" />
|
13
|
+
<link rel="alternate" type="application/atom+xml" title="RSS" href="/tumblog/rss.xml"/>
|
14
|
+
|
15
|
+
|
16
|
+
<link rel="stylesheet" href="/css/tumblog.css" type="text/css" media="screen, projection" />
|
17
|
+
</head>
|
18
|
+
<body>
|
19
|
+
|
20
|
+
<h1>
|
21
|
+
<a href="/">Fowl Friends</a>
|
22
|
+
<a href="/tumblog/rss.xml"><img src="/images/tumblog/rss.gif" id="rss" alt="RSS" /></a>
|
23
|
+
</h1>
|
24
|
+
|
25
|
+
<div id="content">
|
26
|
+
<div id="description">
|
27
|
+
<div>
|
28
|
+
<p><a href="/tumblog/archive">Archive</a></p>
|
29
|
+
</div>
|
30
|
+
</div>
|
31
|
+
|
32
|
+
<%= @content %>
|
33
|
+
|
34
|
+
<div id="footer">
|
35
|
+
<%= content_for :footer %>
|
36
|
+
|
37
|
+
<div id="credit">
|
38
|
+
Powered by <a href="http://webby.rubyforge.org/">Webby</a>
|
39
|
+
</div>
|
40
|
+
</div>
|
41
|
+
|
42
|
+
</div>
|
43
|
+
</body>
|
44
|
+
</html>
|
@@ -0,0 +1,15 @@
|
|
1
|
+
---
|
2
|
+
filter: erb
|
3
|
+
layout: tumblog/default
|
4
|
+
---
|
5
|
+
<div class="post">
|
6
|
+
<%= tumblog_date(@page.created_at) %>
|
7
|
+
<a href="<%= @page.url %>">
|
8
|
+
<img src="/images/tumblog/permalink.gif" class="permalink" alt="permalink" />
|
9
|
+
</a>
|
10
|
+
|
11
|
+
<div class="<%= @page.tumblog_type %>">
|
12
|
+
<h2><%= link_to_page(@page) %></h2>
|
13
|
+
<%= @content %>
|
14
|
+
</div>
|
15
|
+
</div>
|
@@ -0,0 +1,32 @@
|
|
1
|
+
|
2
|
+
require 'time'
|
3
|
+
|
4
|
+
module TumblogHelper
|
5
|
+
|
6
|
+
DAYS = {}
|
7
|
+
(1..31).each {|day| DAYS[day] = "%dth" % day}
|
8
|
+
DAYS[1] = "1st"
|
9
|
+
DAYS[2] = "2nd"
|
10
|
+
DAYS[3] = "3rd"
|
11
|
+
DAYS[21] = "21st"
|
12
|
+
DAYS[22] = "22nd"
|
13
|
+
DAYS[23] = "23rd"
|
14
|
+
DAYS[31] = "31st"
|
15
|
+
|
16
|
+
def tumblog_date( time )
|
17
|
+
<<-HTML
|
18
|
+
<div class="date">
|
19
|
+
<div class="date_brick">
|
20
|
+
#{Time::RFC2822_MONTH_NAME.at(time.month-1)}<br />
|
21
|
+
#{TumblogHelper::DAYS[time.day]}
|
22
|
+
</div>
|
23
|
+
#{Time::RFC2822_DAY_NAME.at(time.wday)}
|
24
|
+
</div>
|
25
|
+
HTML
|
26
|
+
end
|
27
|
+
|
28
|
+
end # module TumblogHelper
|
29
|
+
|
30
|
+
Webby::Helpers.register(TumblogHelper)
|
31
|
+
|
32
|
+
# EOF
|
@@ -0,0 +1,30 @@
|
|
1
|
+
|
2
|
+
namespace :tumblog do
|
3
|
+
|
4
|
+
# iterate over all the files in the "templates/tumblog" folder and create a
|
5
|
+
# rake task corresponding to each file found
|
6
|
+
FileList["#{Webby.site.template_dir}/tumblog/*"].each do |template|
|
7
|
+
next unless test(?f, template)
|
8
|
+
name = template.pathmap('%n')
|
9
|
+
|
10
|
+
desc "Create a new tumblog #{name}"
|
11
|
+
task name do |t|
|
12
|
+
page = Webby.site.args.page
|
13
|
+
title = Webby.site.args.title
|
14
|
+
dir = Webby.site.args.dir
|
15
|
+
|
16
|
+
# if no directory was given use the default tumblog directory (underneath
|
17
|
+
# the content directory)
|
18
|
+
dir = Webby.site.tumblog_dir if dir.empty?
|
19
|
+
dir = File.join(dir, Time.now.strftime('%Y%m'))
|
20
|
+
|
21
|
+
page = File.join(dir, File.basename(page))
|
22
|
+
page = Webby::Builder.create(page, :from => template,
|
23
|
+
:locals => {:title => title, :directory => dir})
|
24
|
+
exec(::Webby.editor, page) unless ::Webby.editor.nil?
|
25
|
+
end
|
26
|
+
end # each
|
27
|
+
|
28
|
+
end # namespace :tumblog
|
29
|
+
|
30
|
+
# EOF
|
@@ -0,0 +1,40 @@
|
|
1
|
+
---
|
2
|
+
title: A New Atom Feed
|
3
|
+
subtitle: A really swell blog built with Webby
|
4
|
+
site: fake-n-site.org
|
5
|
+
author: Author's Name
|
6
|
+
email: author@fake-n-site.org
|
7
|
+
extension: xml
|
8
|
+
layout: nil
|
9
|
+
dirty: true
|
10
|
+
filter: erb
|
11
|
+
---
|
12
|
+
<?xml version="1.0" encoding="utf-8"?>
|
13
|
+
<feed xmlns="http://www.w3.org/2005/Atom">
|
14
|
+
|
15
|
+
<title><%%= h(@page.title) %></title>
|
16
|
+
<subtitle><%%= h(@page.subtitle) %></subtitle>
|
17
|
+
<link href="http://<%%= @page.site %>/<%= directory %>/" rel="self" />
|
18
|
+
<link href="http://<%%= @page.site %>/" />
|
19
|
+
<updated><%%= Time.now.xmlschema %></updated>
|
20
|
+
<author>
|
21
|
+
<name><%%= h(@page.author) %></name>
|
22
|
+
<email><%%= h(@page.email) %></email>
|
23
|
+
</author>
|
24
|
+
<id>http://<%%= @page.site %>/</id>
|
25
|
+
<%% @pages.find(:limit => 10,
|
26
|
+
:in_directory => '<%= directory %>',
|
27
|
+
:recursive => true,
|
28
|
+
:sort_by => 'mtime',
|
29
|
+
:reverse => true).each do |article|
|
30
|
+
next if article == @page
|
31
|
+
%>
|
32
|
+
<entry>
|
33
|
+
<title><%%= h(article.title) %></title>
|
34
|
+
<link href="<%%= article.url %>" />
|
35
|
+
<id>tag:<%%= @page.site %>,<%%= article.created_at.strftime('%Y-%m-%d') %>:<%%= article.created_at.to_i %></id>
|
36
|
+
<updated><%%= article.created_at.xmlschema %></updated>
|
37
|
+
<content type="html"><%%= h(render(article)) %></content>
|
38
|
+
</entry>
|
39
|
+
<%% end %>
|
40
|
+
</feed>
|
@@ -0,0 +1,12 @@
|
|
1
|
+
---
|
2
|
+
title: <%= title %>
|
3
|
+
created_at: <%= Time.now.to_y %>
|
4
|
+
author: Your Name
|
5
|
+
filter:
|
6
|
+
- textile
|
7
|
+
layout: tumblog/post
|
8
|
+
tumblog_type: conversation
|
9
|
+
---
|
10
|
+
* %(label)me :% Why did the chicken cross the road?
|
11
|
+
* %(label)Buddha :% If you ask this question, you deny your own chicken nature.
|
12
|
+
* %(label)Darwin :% Chickens, over great periods of time, have been naturally selected in such a way that they are now genetically predisposed to cross roads.
|
@@ -0,0 +1,13 @@
|
|
1
|
+
---
|
2
|
+
title: <%= title %>
|
3
|
+
created_at: <%= Time.now.to_y %>
|
4
|
+
author: Your Name
|
5
|
+
filter:
|
6
|
+
- erb
|
7
|
+
- textile
|
8
|
+
layout: tumblog/post
|
9
|
+
tumblog_type: photo
|
10
|
+
---
|
11
|
+
!http://www.madcitychickens.com/images/bttrcups_tree.jpg(<%%= h(@page.title) %>)!
|
12
|
+
|
13
|
+
p(caption). via "Mad City Chickens":http://www.madcitychickens.com/
|
@@ -0,0 +1,12 @@
|
|
1
|
+
---
|
2
|
+
title: <%= title %>
|
3
|
+
created_at: <%= Time.now.to_y %>
|
4
|
+
author: Your Name
|
5
|
+
filter:
|
6
|
+
- textile
|
7
|
+
layout: tumblog/post
|
8
|
+
tumblog_type: regular
|
9
|
+
---
|
10
|
+
The *chicken* (_Gallus gallus_, sometimes _G. gallus domesticus_) is a domesticated fowl likely descended from the wild Indian and southeast Asian Red Junglefowl (_Gallus gallus_) and the related Grey Junglefowl (_G. sonneratii_). Traditionally it has been widely accepted that the chicken was descended solely from the former, as hybrids of both wild types tended toward sterility; but recent genetic work has revealed that the genotype for yellow skin present in the domestic fowl is not present in what is otherwise its closest kin, the Red Junglefowl. It is deemed most likely, then, that the yellow skin trait in domestic birds originated in the Grey Junglefowl.
|
11
|
+
|
12
|
+
The chicken is one of the most common and widespread domestic animals. With a population of more than 24 billion in 2003, there are more chickens in the world than any other bird. Humans keep chickens primarily as a source of food, with both their meat and their eggs consumed.
|