webby 0.8.4 → 0.9.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (165) hide show
  1. data/History.txt +19 -0
  2. data/Manifest.txt +104 -91
  3. data/README.txt +27 -45
  4. data/Rakefile +4 -5
  5. data/bin/webby +2 -1
  6. data/bin/webby-gen +8 -0
  7. data/{data/Rakefile → examples/blog/Sitefile} +0 -2
  8. data/examples/{webby → blog}/tasks/blog.rake +5 -4
  9. data/{data → examples/blog}/templates/atom_feed.erb +10 -11
  10. data/{data → examples/blog}/templates/blog/month.erb +1 -1
  11. data/{data → examples/blog}/templates/blog/post.erb +1 -0
  12. data/{data → examples/blog}/templates/blog/year.erb +1 -1
  13. data/examples/presentation/{Rakefile → Sitefile} +0 -4
  14. data/examples/presentation/content/{_sample_code.txt → presentation/_sample_code.txt} +0 -0
  15. data/examples/presentation/content/{index.txt → presentation/index.txt} +0 -0
  16. data/{data/content → examples/presentation/content/presentation}/s5/blank.gif +0 -0
  17. data/{data/content → examples/presentation/content/presentation}/s5/bodybg.gif +0 -0
  18. data/{data/content → examples/presentation/content/presentation}/s5/framing.css +0 -0
  19. data/{data/content → examples/presentation/content/presentation}/s5/iepngfix.htc +0 -0
  20. data/{data/content → examples/presentation/content/presentation}/s5/opera.css +0 -0
  21. data/{data/content → examples/presentation/content/presentation}/s5/outline.css +0 -0
  22. data/{data/content → examples/presentation/content/presentation}/s5/pretty.css +0 -0
  23. data/{data/content → examples/presentation/content/presentation}/s5/print.css +0 -0
  24. data/{data/content → examples/presentation/content/presentation}/s5/s5-core.css +0 -0
  25. data/{data/content → examples/presentation/content/presentation}/s5/slides.css +0 -0
  26. data/{data/content → examples/presentation/content/presentation}/s5/slides.js +0 -0
  27. data/examples/presentation/layouts/{presentation.rhtml → presentation.txt} +3 -3
  28. data/examples/presentation/templates/{_partial.erb → _code_partial.erb} +0 -0
  29. data/examples/tumblog/Sitefile +9 -0
  30. data/examples/tumblog/content/css/tumblog.css +308 -0
  31. data/examples/tumblog/content/images/tumblog/permalink.gif +0 -0
  32. data/examples/tumblog/content/images/tumblog/rss.gif +0 -0
  33. data/examples/tumblog/content/tumblog/200806/the-noble-chicken/index.txt +12 -0
  34. data/examples/tumblog/content/tumblog/200807/historical-perspectives-on-the-classic-chicken-joke/index.txt +12 -0
  35. data/examples/tumblog/content/tumblog/200807/mad-city-chickens/index.txt +10 -0
  36. data/examples/tumblog/content/tumblog/200807/the-wisdom-of-the-dutch/index.txt +11 -0
  37. data/examples/tumblog/content/tumblog/200807/up-a-tree/index.txt +13 -0
  38. data/examples/tumblog/content/tumblog/index.txt +37 -0
  39. data/examples/tumblog/content/tumblog/rss.txt +37 -0
  40. data/examples/tumblog/layouts/tumblog/default.txt +44 -0
  41. data/examples/tumblog/layouts/tumblog/post.txt +15 -0
  42. data/examples/tumblog/lib/tumblog_helper.rb +32 -0
  43. data/examples/tumblog/tasks/tumblog.rake +30 -0
  44. data/examples/tumblog/templates/atom_feed.erb +40 -0
  45. data/examples/tumblog/templates/tumblog/conversation.erb +12 -0
  46. data/examples/tumblog/templates/tumblog/link.erb +10 -0
  47. data/examples/tumblog/templates/tumblog/photo.erb +13 -0
  48. data/examples/tumblog/templates/tumblog/post.erb +12 -0
  49. data/examples/tumblog/templates/tumblog/quote.erb +11 -0
  50. data/examples/webby/{Rakefile → Sitefile} +2 -2
  51. data/examples/webby/content/communicate/index.txt +28 -0
  52. data/examples/webby/content/css/background.gif +0 -0
  53. data/examples/webby/content/css/site.css +52 -20
  54. data/examples/webby/content/index.txt +7 -8
  55. data/examples/webby/content/learn/index.txt +28 -0
  56. data/examples/webby/content/reference/index.txt +3 -1
  57. data/examples/webby/content/release-notes/rel-0-9-0/index.txt +73 -0
  58. data/examples/webby/content/sitemap.txt +31 -0
  59. data/examples/webby/content/tips_and_tricks/index.txt +1 -1
  60. data/examples/webby/content/tutorial/index.txt +17 -17
  61. data/examples/webby/content/{manual → user-manual}/index.txt +53 -50
  62. data/examples/webby/layouts/{default.rhtml → default.txt} +8 -15
  63. data/examples/webby/templates/page.erb +1 -1
  64. data/examples/website/Sitefile +7 -0
  65. data/{data → examples/website}/content/css/blueprint/License.txt +0 -0
  66. data/{data → examples/website}/content/css/blueprint/Readme.txt +0 -0
  67. data/{data → examples/website}/content/css/blueprint/compressed/print.css +0 -0
  68. data/{data → examples/website}/content/css/blueprint/compressed/screen.css +0 -0
  69. data/{data → examples/website}/content/css/blueprint/lib/forms.css +0 -0
  70. data/{data → examples/website}/content/css/blueprint/lib/grid.css +0 -0
  71. data/{data → examples/website}/content/css/blueprint/lib/grid.png +0 -0
  72. data/{data → examples/website}/content/css/blueprint/lib/ie.css +0 -0
  73. data/{data → examples/website}/content/css/blueprint/lib/reset.css +0 -0
  74. data/{data → examples/website}/content/css/blueprint/lib/typography.css +0 -0
  75. data/{data → examples/website}/content/css/blueprint/plugins/buttons/Readme +0 -0
  76. data/{data → examples/website}/content/css/blueprint/plugins/buttons/buttons.css +0 -0
  77. data/{data → examples/website}/content/css/blueprint/plugins/buttons/icons/cross.png +0 -0
  78. data/{data → examples/website}/content/css/blueprint/plugins/buttons/icons/key.png +0 -0
  79. data/{data → examples/website}/content/css/blueprint/plugins/buttons/icons/tick.png +0 -0
  80. data/{data → examples/website}/content/css/blueprint/plugins/css-classes/Readme +0 -0
  81. data/{data → examples/website}/content/css/blueprint/plugins/css-classes/css-classes.css +0 -0
  82. data/{data → examples/website}/content/css/blueprint/plugins/fancy-type/Readme +0 -0
  83. data/{data → examples/website}/content/css/blueprint/plugins/fancy-type/fancy-type-compressed.css +0 -0
  84. data/{data → examples/website}/content/css/blueprint/plugins/fancy-type/fancy-type.css +0 -0
  85. data/{data → examples/website}/content/css/blueprint/print.css +0 -0
  86. data/{data → examples/website}/content/css/blueprint/screen.css +0 -0
  87. data/{data → examples/website}/content/css/coderay.css +0 -0
  88. data/{data → examples/website}/content/css/site.css +0 -0
  89. data/{data → examples/website}/content/index.txt +2 -1
  90. data/{data/layouts/default.rhtml → examples/website/layouts/default.txt} +1 -1
  91. data/{data → examples/website}/lib/breadcrumbs.rb +0 -0
  92. data/{data → examples/website}/templates/_partial.erb +0 -0
  93. data/{data → examples/website}/templates/page.erb +0 -0
  94. data/{data → examples/website}/templates/presentation.erb +0 -0
  95. data/lib/webby/apps/generator.rb +283 -0
  96. data/lib/webby/apps/main.rb +221 -0
  97. data/lib/webby/apps.rb +12 -0
  98. data/lib/webby/builder.rb +8 -10
  99. data/lib/webby/core_ext/enumerable.rb +11 -0
  100. data/lib/webby/{utils.rb → core_ext/hash.rb} +2 -26
  101. data/lib/webby/core_ext/kernel.rb +21 -0
  102. data/lib/webby/core_ext/string.rb +163 -0
  103. data/lib/webby/core_ext/time.rb +9 -0
  104. data/lib/webby/filters/haml.rb +13 -5
  105. data/lib/webby/filters/markdown.rb +12 -4
  106. data/lib/webby/filters/outline.rb +3 -2
  107. data/lib/webby/filters/sass.rb +12 -4
  108. data/lib/webby/filters/textile.rb +12 -4
  109. data/lib/webby/filters/tidy.rb +10 -8
  110. data/lib/webby/filters.rb +2 -0
  111. data/lib/webby/helpers/graphviz_helper.rb +1 -2
  112. data/lib/webby/helpers/tex_img_helper.rb +6 -10
  113. data/lib/webby/renderer.rb +5 -3
  114. data/lib/webby/resources/layout.rb +1 -1
  115. data/lib/webby/resources/page.rb +1 -1
  116. data/lib/webby/resources/resource.rb +13 -3
  117. data/lib/webby/resources.rb +16 -0
  118. data/{data → lib/webby}/tasks/build.rake +0 -0
  119. data/{examples/presentation → lib/webby}/tasks/create.rake +1 -1
  120. data/{data → lib/webby}/tasks/deploy.rake +0 -0
  121. data/{examples → lib}/webby/tasks/growl.rake +4 -1
  122. data/{data → lib/webby}/tasks/heel.rake +0 -0
  123. data/{data → lib/webby}/tasks/validate.rake +0 -0
  124. data/lib/webby.rb +11 -5
  125. data/spec/core_ext/hash_spec.rb +47 -0
  126. data/spec/core_ext/string_spec.rb +110 -0
  127. data/spec/core_ext/time_spec.rb +19 -0
  128. data/spec/webby/apps/generator_spec.rb +111 -0
  129. data/spec/webby/apps/main_spec.rb +75 -0
  130. data/spec/webby/helpers/capture_helper_spec.rb +1 -1
  131. data/spec/webby/resources_spec.rb +17 -0
  132. data/tasks/gem.rake +10 -2
  133. data/tasks/git.rake +41 -0
  134. data/tasks/rubyforge.rake +2 -2
  135. data/tasks/website.rake +38 -38
  136. metadata +125 -98
  137. data/data/tasks/blog.rake +0 -71
  138. data/data/tasks/create.rake +0 -22
  139. data/data/tasks/growl.rake +0 -12
  140. data/data/tasks/setup.rb +0 -17
  141. data/examples/presentation/content/s5/blank.gif +0 -0
  142. data/examples/presentation/content/s5/bodybg.gif +0 -0
  143. data/examples/presentation/content/s5/framing.css +0 -23
  144. data/examples/presentation/content/s5/iepngfix.htc +0 -42
  145. data/examples/presentation/content/s5/opera.css +0 -7
  146. data/examples/presentation/content/s5/outline.css +0 -15
  147. data/examples/presentation/content/s5/pretty.css +0 -86
  148. data/examples/presentation/content/s5/print.css +0 -1
  149. data/examples/presentation/content/s5/s5-core.css +0 -9
  150. data/examples/presentation/content/s5/slides.css +0 -3
  151. data/examples/presentation/content/s5/slides.js +0 -553
  152. data/examples/presentation/tasks/blog.rake +0 -71
  153. data/examples/presentation/tasks/build.rake +0 -27
  154. data/examples/presentation/tasks/deploy.rake +0 -22
  155. data/examples/presentation/tasks/growl.rake +0 -12
  156. data/examples/presentation/tasks/heel.rake +0 -28
  157. data/examples/presentation/tasks/setup.rb +0 -17
  158. data/examples/presentation/tasks/validate.rake +0 -19
  159. data/examples/webby/tasks/build.rake +0 -27
  160. data/examples/webby/tasks/create.rake +0 -22
  161. data/examples/webby/tasks/deploy.rake +0 -22
  162. data/examples/webby/tasks/heel.rake +0 -28
  163. data/examples/webby/tasks/setup.rb +0 -17
  164. data/examples/webby/tasks/validate.rake +0 -19
  165. data/lib/webby/main.rb +0 -227
@@ -1,6 +1,4 @@
1
1
 
2
- load 'tasks/setup.rb'
3
-
4
2
  task :default => :build
5
3
 
6
4
  desc 'deploy the website to Rubyforge'
@@ -16,4 +14,6 @@ SITE.uv[:line_numbers] = true
16
14
 
17
15
  task :autobuild => :growl
18
16
 
17
+ SITE.site_root = "http://webby.rubyforge.org"
18
+
19
19
  # EOF
@@ -0,0 +1,28 @@
1
+ ---
2
+ title: Communicate
3
+ created_at: 2008-08-24 15:37:45.654428 -06:00
4
+ filter:
5
+ - erb
6
+ - textile
7
+ ---
8
+ h1. <%= h(@page.title) %>
9
+
10
+ There is a community of people using Webby right now to make real web pages and publish them on the internet. They have walked down this path, and some have chosen to share their knowledge %(quiet)&#40;aren't they a nice bunch!)%. The Webby developer is also known to frequent the list -- your questions will most definitely find an answer ... or they might have been answered already.
11
+
12
+ p(pull). *<%= link_to('Forum', 'http://groups.google.com/group/webby-forum') %>*
13
+
14
+ p(pulltext). The Google group dedicated to Webby and _ASCII Alchemy_.
15
+
16
+ p(pull). *Reporting Bugs*
17
+
18
+ p(pulltext). The occasional bug does rear its ugly head from time to time. If this happens please report it either by e-mailing the author or in a post to the discussion group. %(quiet)Note to self: look into a real bug tracking system.%
19
+
20
+ h2. Elsewhere
21
+
22
+ A few kind souls have written up their experiences with Webby along with some of their tips and tricks.
23
+
24
+ * <%= link_to('Building Static Websites with Webby', 'http://clarkware.com/cgi/blosxom/2008/08/06#Webby') %> -- Mike Clark
25
+
26
+ h2. Errata
27
+
28
+ If you're interested in the development of Webby, you can follow along at home by watching the <%= link_to('github repository', 'http://github.com/TwP/webby/tree/master') %>.
@@ -20,8 +20,10 @@ sass_options:
20
20
  @import blueprint/screen.css
21
21
 
22
22
  body
23
+ :margin 0
23
24
  :color = !text
24
25
  :font-family Verdana, sans-serif
26
+ :background white url('background.gif') repeat-x left top
25
27
 
26
28
  // Headings
27
29
  // ------------------------------------------------------------------------
@@ -44,13 +46,13 @@ blockquote
44
46
 
45
47
  pre
46
48
  :margin-left 18px
47
- :padding 8px
49
+ :padding 8px 8px 8px 18px
48
50
  :color = !code
49
51
  :font-family monospace, courier
50
52
  :overflow auto
51
- :background = !box_bg
52
- :border = 1px solid !border
53
- :border-left = 7px solid !border
53
+ // :background = !box_bg
54
+ // :border = 1px solid !border
55
+ :border-left = 3px solid !border
54
56
 
55
57
  hr
56
58
  :background = !highlight
@@ -78,31 +80,42 @@ p.quiet
78
80
  // My Site Stylings
79
81
  // ------------------------------------------------------------------------
80
82
  #header
81
-
82
- #navigation
83
+ :margin 0 0 25px 0
84
+ :padding-top 20px
85
+ a
86
+ :color = !header
87
+ :text-decoration none
88
+ h1
89
+ :margin 0
90
+ :font-size 2.0em
91
+ :letter-spacing 0.25em
92
+ p
93
+ :font-style italic
94
+ :font-weight normal
95
+ :color = !quiet
83
96
  ul
84
- :margin-left 0
85
- :text-align right
86
- :font-size 16px
87
- :list-style-type none
97
+ :float right
98
+ :margin 0
99
+ :padding 0
100
+ :text-align right
101
+ :font-size 1.0em
102
+ :list-style-type circle
88
103
  li
89
- :display block
90
- :padding-right 5px
91
- :background-color = !box_bg
104
+ :display inline
105
+ :margin 0 0 0 2.5em
92
106
  a
93
- :display block
94
- :text-decoration none
95
- :margin-right -5px
96
- :padding-right 5px
97
- :background-color white
107
+ :color = !quiet
108
+ :font-weight bold
98
109
  &:hover
99
- :background-color = !highlight
110
+ :color = !header
100
111
 
101
112
  #footer
113
+ :margin-top 18px
114
+ :font-size 0.8em
102
115
  hr
103
116
  :margin-bottom 18px
104
117
  p
105
- :text-align right
118
+ :text-align center
106
119
 
107
120
  .CodeRay
108
121
  pre
@@ -161,4 +174,23 @@ div.desc
161
174
  ul
162
175
  :margin-bottom 0
163
176
 
177
+ p.TODO
178
+ :color white
179
+ :background-color red
180
+ :font-weight bold
181
+ :padding 5px 0.5em
182
+
183
+ p.pull
184
+ :float left
185
+ :clear left
186
+ :margin 0 10px 0 -120px
187
+ :width 110px
188
+ :text-align right
189
+
190
+ p.pulltext
191
+ :float left
192
+ :clear right
193
+ :margin-right 10px
194
+ :width 670px
195
+
164
196
  // EOF
@@ -1,6 +1,6 @@
1
1
  ---
2
- title: Home
3
- created_at: Tue Aug 21 11:25:06 -0600 2007
2
+ title: Webby
3
+ created_at: 2007-08-21 11:25:06.000000 -06:00
4
4
  filter: textile
5
5
  ---
6
6
  *Webby* is a fantastic little website management system. It would be called a _content management system_ if it were a bigger kid. But, it's just a runt with a special knack for transforming text. And that's really all it does - manages the legwork of turning text into something else, an *ASCII Alchemist* if you will.
@@ -9,7 +9,7 @@ Webby works by combining the contents of a *page* with a *layout* to produce HTM
9
9
 
10
10
  Install Webby and try it out!
11
11
 
12
- sudo gem install webby
12
+ pre. sudo gem install webby
13
13
 
14
14
  h2. Features
15
15
 
@@ -27,11 +27,10 @@ h2. But Wait! There's More!
27
27
 
28
28
  Webby has a great _autobuild_ feature that continuously generates HTML whenever the *pages* or *layouts* change. The HTML is served up via "heel":http://copiousfreetime.rubyforge.org/heel/, a static file webserver based on mongrel. Whenever you change a page, you can immediately see those changes without having to run any commands.
29
29
 
30
- $ rake autobuild
31
- heel --root output --daemonize
32
- [10:21:26] INFO: starting autobuild (Ctrl-C to stop)
33
- [10:21:26] INFO: creating output/index.html
34
- [10:22:57] INFO: creating output/index.html
30
+ pre. $ webby autobuild
31
+ [10:21:26] INFO: starting autobuild (Ctrl-C to stop)
32
+ [10:21:26] INFO: creating output/index.html
33
+ [10:22:57] INFO: creating output/index.html
35
34
 
36
35
  Webby is not limited to producing HTML. By no means! Do you ever get tired of repeating the same color code *#D3C4A2* in your CSS files? Webby can help. Need some customized JavaScript for your website. Webby can help. Anytime you find yourself repeating the same bit of text over and over, then you should be using Webby.
37
36
 
@@ -0,0 +1,28 @@
1
+ ---
2
+ title: Learn
3
+ created_at: 2008-08-24 15:36:06.596051 -06:00
4
+ filter:
5
+ - erb
6
+ - textile
7
+ ---
8
+ h1. <%= h(@page.title) %>
9
+
10
+ This section is devoted to learning more about Webby. Located below are the various "official" documents to assist you on your way to becoming prolific with Webby.
11
+
12
+ If you cannot find your answer here, head on over to the <%= link_to_page('Communicate') %> section where the mailing list might help you.
13
+
14
+ p(pull). *<%= link_to_page('Tutorial') %>*
15
+
16
+ p(pulltext). The tutorial is a great introduction to Webby if you want to hit the ground running and figure things out as you go. Following along with the tutorial on your own computer will get you comfortable with the basic concepts of Webby.
17
+
18
+ p(pull). *<%= link_to_page('User Manual') %>*
19
+
20
+ p(pulltext). The user manual provides a more in-depth look into Webby. It assumes no prior experience with Webby, and it goes into more detail about the various aspects of creating a webby site and working with Webby itself. The user manual is the place to go if you want to go beyond the basics.
21
+
22
+ p(pull). *<%= link_to_page('Reference') %>*
23
+
24
+ p(pulltext). The reference does not provide an introduction to Webby. Instead, it is an indexed collection of the various Webby features with a brief explanation of each. It is useful when you vaguely remember reading something about filters and only need a quick refresher of the details without instructional text.
25
+
26
+ p(pull). *<%= link_to_page('Release Notes', :title => 'Release 0.9.0') %>*
27
+
28
+ p(pulltext). These are the release notes for past and present versions of Webby. Actually, it's only for the current version of Webby since formal release notes were only recently thought of by the developer. %(quiet)Bad developer! No latte!!%
@@ -13,9 +13,11 @@ content_for_head: |
13
13
 
14
14
  p(title). Table of Contents
15
15
 
16
- <toc />
16
+ <toc toc_range="h2-h6" />
17
17
  </div>
18
18
 
19
+ h1. <%= h(@page.title) %>
20
+
19
21
  h3. Resources
20
22
 
21
23
  Resources are the files that are found in the _content_ and _layouts_ folders of a webby site. They come in the following four flavors:
@@ -0,0 +1,73 @@
1
+ ---
2
+ title: Release 0.9.0
3
+ created_at: 2008-08-18 16:05:25.189950 -06:00
4
+ filter:
5
+ - erb
6
+ - textile
7
+ ---
8
+ h2. <%= h(@page.title) %>
9
+
10
+ Release 0.9.0 adds new features and fixes some bugs. Most notably is the move away from the rake command line application, and the daily usage of the *webby* command line application to build sites.
11
+
12
+ * 2 major enhancements
13
+ ** The "rake" command line tool has been replaced by the "webby" command line tool for day to day site tasks
14
+ ** Now using the "rdiscount" gem for markdown syntax
15
+ * 4 minor enhancements
16
+ ** Layouts can exist in subdirectories of the layouts folder
17
+ ** Addition of a "tumblog" template
18
+ ** Addition of a sitemap file (Ana Nelson)
19
+ ** Updated to version 6.4.2 of ImageMagick for tex2img conversions
20
+ * 5 bug fixes
21
+ ** Better error message when an unknown filter is given
22
+ ** Table of contents generation bug
23
+ ** Failing to clean out the "content_for" cache when doing a multi-page render
24
+ ** Explicitly loading the RedCloth gem
25
+ ** Handling exceptions from system calls on the Windows platform
26
+
27
+ h3. Steps to Upgrade a Site
28
+
29
+ * rename *Rakefile* to *Sitefile*
30
+ * edit the *Sitefile* and remove the @load tasks/setup.rb@ line
31
+ * remove *setup.rb* from the *tasks* folder
32
+ * remove the following files from the *tasks* folder _unless you have modified them_
33
+ ** build.rake
34
+ ** create.rake
35
+ ** deploy.rake
36
+ ** growl.rake
37
+ ** heel.rake
38
+ ** validate.rake
39
+
40
+ h3. Rationale
41
+
42
+ *webby vs. rake*
43
+
44
+ The most prominent change in this release is the move away from the rake command line application. The webby command line application has taken its place. The impetus for this change is rake's inability to handle command line arguments being passed to individual tasks. Specifically, when creating a new page in a site the filename of the page is passed on the command line. Much "hackery" was taking place behind the scenes in order for this to work with the rake command line app.
45
+
46
+ Since "hackery" is prone to break, the immediate benefit of the webby command line app is future stability in the face of changes to rake. The rake infrastructure is still used under the hood, but the webby command line app now handles parsing of tasks and task arguments. This is a much more graceful solution.
47
+
48
+ *webby-gen*
49
+
50
+ A second command line application has been created -- *webby-gen*. When a new webby site was created with the old webby command line app, it was an "all or nothing" affair. Blueprint style sheets were created alongside S5 presentation templates with a smattering of blog support thrown in for good measure. Each of these can now be created independently of the others. Furthermore, a site template can be instantiated into an already existing site. Support for S5 presentations can be included into a site if it is needed.
51
+
52
+ An attempt was made to roll all this functionality into the webby command line app. However, all the options proved to be cumbersome for one utility. Occam's razor was applied to split the two.
53
+
54
+ *sitefile*
55
+
56
+ Slightly related to the "webby vs. rake" section above, I wanted to make a distinction between the "old way" of doing things and the "new way" of doing things. Of all the choices made in the release this was the most capricious.
57
+
58
+ *tasks*
59
+
60
+ It simply made sense to move the vast majority of the common website tasks into the webby gem itself. I found that these same task files were repeated over and over again in all the sites, and they were not being modified at all. This fact combined with the move to the webby command line app provided for a convenient way to use the tasks from the webby gem.
61
+
62
+ Some of the site templates (blog and tumblog, for example) still create rake tasks in the tasks folder. These are examples of specific behaviors that are good to be able to dissect for inspiration.
63
+
64
+ h3. Thanks
65
+
66
+ Thanks to everyone who has helped make Webby possible!
67
+ If you've made a website with webby, thanks.
68
+ If you've contributed some source code, thanks.
69
+ If you've written up some documentation, thanks.
70
+ If you've told a friend, thanks.
71
+
72
+ Blessings,
73
+ TwP
@@ -0,0 +1,31 @@
1
+ ---
2
+ #
3
+ # Define the following in your Rakefile or some
4
+ # other location which will be accessed by tasks/setup.rb
5
+ #
6
+ # SITE.site_root = "http://webby.rubyforge.org"
7
+ #
8
+ extension: xml
9
+ layout: nil
10
+ index: false
11
+ dirty: true
12
+ filter:
13
+ - erb
14
+ ---
15
+ <?xml version="1.0" encoding="utf-8"?>
16
+ <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
17
+ <% @pages.find(:in_directory => "/", :recursive => true) do |p|
18
+ next if p.created_at.nil?
19
+ next unless p['index'] || p['index'].nil? -%>
20
+ <url>
21
+ <loc><%= SITE.site_root %><%= p.url %></loc>
22
+ <lastmod><%= p.mtime.xmlschema %></lastmod>
23
+ <% if p['changefreq'] || SITE.changefreq -%>
24
+ <changefreq><%= p['changefreq'] || SITE.changefreq %></changefreq>
25
+ <% end -%>
26
+ <% if p['priority'] || SITE.priority -%>
27
+ <priority><%= p['priority'] || SITE.priority %></priority>
28
+ <% end -%>
29
+ </url>
30
+ <% end -%>
31
+ </urlset>
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  title: Tips & Tricks
3
- created_at: Wed Aug 29 08:57:11 -0600 2007
3
+ created_at: 2007-08-29 08:57:11.000000 -06:00
4
4
  filter:
5
5
  - textile
6
6
  - outline
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  title: Tutorial
3
- created_at: Tue Aug 21 17:02:40 -0600 2007
3
+ created_at: 2007-08-21 17:02:40.000000 -06:00
4
4
  filter: textile
5
5
  ---
6
6
  h2. Require
@@ -14,13 +14,13 @@ h2. Create a Site
14
14
  You need a catchy name for your website to survive in this Web 2.0 world. Webby is distinctly Web 1.0 (or maybe Web 0.5) so we'll use the name *my_site*.
15
15
 
16
16
  <pre class="code">
17
- webby my_site
17
+ webby-gen website my_site
18
18
  </pre>
19
19
 
20
20
  This command creates a new folder named _my_site_, and the new Webby based website resides there. Change directories to the _my_site_ folder and do a listing. You will see the following files and folders:
21
21
 
22
22
  <pre class="code">
23
- Rakefile
23
+ Sitefile
24
24
  content/
25
25
  layouts/
26
26
  lib/
@@ -33,13 +33,13 @@ h2. Build Your Site
33
33
 
34
34
  What? Didn't we just do that?
35
35
 
36
- Webby creates a site template - the larval form of your new website. "Rake":http://docs.rubyrake.org/ (another command line tool) is used to generate the HTML files for your site - a unique, beautiful butterfly.
36
+ Webby creates a site template - the larval form of your new website. The _webby_ command line tool is used to generate the HTML files for your site - a unique, beautiful butterfly.
37
37
 
38
38
  <pre class="code">
39
- rake
39
+ webby
40
40
  </pre>
41
41
 
42
- Again, you will see lots of output scrolling across the screen. This is the rake task copying files from the _content_ folder to the _output_ folder. Some files are copied "as is", while others are compiled into HTML using your markup language of choice.
42
+ Again, you will see lots of output scrolling across the screen. This is Webby copying files from the _content_ folder to the _output_ folder. Some files are copied "as is", while others are compiled into HTML using your markup language of choice.
43
43
 
44
44
  Point your web browser to *my_site/output/index.html* to see what your new website looks like.
45
45
 
@@ -72,33 +72,33 @@ The content of this page is not HTML, but it ends up that way. How? Webby uses _
72
72
 
73
73
  The erb filter (erb stands for "embedded Ruby") allows Webby to process Ruby statements found in the page text and to substitute the output of those Ruby statements back into the page text. The Ruby statements appear between @<%= ruby_code %>@ delimiters. The meta-data found at the top of the page is made available through the @@page@ object. You can see from the index.txt file that the page title, "Home Page", will be substituted on the first line.
74
74
 
75
- The textile filter operates on all page text. It is a human readable markup that gets converted into HTML. For example, the line <notextile><code>h2.&nbsp;Litora&nbsp;Sociis</code></notextile> will be converted into @<h2>Litora Sociis</h2>@ by the textile filter. It is a powerful markup language that simplifies web publishing.
75
+ The textile filter operates on all page text. It is a human readable markup that gets converted into HTML. For example, the line <notextile><code>h2.&nbsp;Litora&nbsp;Sociis</code></notextile> will be converted into <notextile><code>&lt;h2&gt;&nbsp;Litora&nbsp;Sociis&lt;/h2&gt;</code></notextile> by the textile filter. It is a powerful markup language that simplifies web publishing.
76
76
 
77
- Okay, back to our regularly scheduled page changes. Go ahead and change the title of the page in the meta-data. Then run rake again.
77
+ Okay, back to our regularly scheduled page changes. Go ahead and change the title of the page in the meta-data. Then run webby again.
78
78
 
79
79
  <pre class="code">
80
- rake
80
+ webby
81
81
  </pre>
82
82
 
83
- You'll notice much less output than before. The rake task only builds those pages that you have modified. You'll also notice, after reloading the page in your browser, that the title has now changed.
83
+ You'll notice much less output than before. Webby only builds those pages that you have modified. You'll also notice, after reloading the page in your browser, that the title has now changed.
84
84
 
85
- Play around with making changes, running rake, and seeing your changes show up in the web browser. Done? All right! Let's go on to the next section.
85
+ Play around with making changes, running webby, and seeing your changes show up in the web browser. Done? All right! Let's go on to the next section.
86
86
 
87
- bq. *TIP* You can simplify this whole process - modify content, rake, view in browser - by running <notextile><code>rake&nbsp;autobuild</code></notextile> on the command line. This starts a build loop that compiles the content of your website as files change. All you need to do now is - modify content, view in browser.
87
+ bq. *TIP* You can simplify this whole process - modify content, webby, view in browser - by running <notextile><code>webby&nbsp;autobuild</code></notextile> on the command line. This starts a build loop that compiles the content of your website as files change. All you need to do now is - modify content, view in browser.
88
88
 
89
89
  h2. Creating a Page
90
90
 
91
91
  Let's tell the world all about your new website. We'll create a new _about_ page that describes what this website is all about, who you are, and the answer to life, the universe, and everything.
92
92
 
93
93
  <pre class="code">
94
- rake create:page about
94
+ webby create:page about
95
95
  </pre>
96
96
 
97
- The output from the command tells you that a new file has been created - @content/about.txt@. You can now edit this page, give it a title "About", and somewhere in there include _42_.
97
+ The output from the command tells you that a new file has been created - @content/about.txt@. You can now edit this page, enter some content, and somewhere in there include _42_.
98
98
 
99
99
  h2. Change the Layout
100
100
 
101
- The next step is to change how the page looks. In fact, we want to change the appearance of all the pages in our website. This is easily done by changing the website layout file in the _layouts_ folder. Open the *layouts/default.rhtml* file in your favorite editor.
101
+ The next step is to change how the page looks. In fact, we want to change the appearance of all the pages in our website. This is easily done by changing the website layout file in the _layouts_ folder. Open the *layouts/default.txt* file in your favorite editor.
102
102
 
103
103
  <pre class="code">
104
104
  ---
@@ -106,7 +106,7 @@ extension: html
106
106
  filter: erb
107
107
  ---
108
108
  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
109
- "DTD/xhtml1-strict.dtd">
109
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
110
110
 
111
111
  <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en-us">
112
112
  <head>
@@ -128,4 +128,4 @@ h2. What Now?
128
128
 
129
129
  Let your creativity run wild!
130
130
 
131
- You can read more about the features of Webby in the "manual":/manual. There you'll discover how to reference layouts other than the default, how to create page templates for simplifying blog posts. Take a look at the "tips &amp; tricks":/tips_and_tricks for more ideas on simplifying your web development work cycle.
131
+ You can read more about the features of Webby in the "user manual":/user-manual. There you'll discover how to reference layouts other than the default, how to create page templates for simplifying blog posts. Take a look at the "tips &amp; tricks":/tips_and_tricks for more ideas on simplifying your web development work cycle.