runeblog 0.2.10 → 0.2.16

Sign up to get free protection for your applications and to get access to all the features.
Files changed (517) hide show
  1. checksums.yaml +4 -4
  2. data/empty_view.tgz +0 -0
  3. data/lib/helpers-blog.rb +46 -24
  4. data/lib/liveblog.rb +66 -39
  5. data/lib/pathmagic.rb +14 -0
  6. data/lib/runeblog.rb +160 -133
  7. data/lib/runeblog_version.rb +1 -1
  8. data/runeblog.gemspec +2 -3
  9. data/test/make_blog.rb +3 -5
  10. metadata +5 -511
  11. data/lib/BAD.liveblog.rb +0 -724
  12. data/lib/KEEP.liveblog +0 -646
  13. data/lib/NEW-liveblog.rb +0 -757
  14. data/lib/OLD-liveblog.rb +0 -661
  15. data/test/.blogs/VERSION +0 -2
  16. data/test/.blogs/config +0 -3
  17. data/test/.blogs/drafts/0001-whats-at-stubbs.lt3 +0 -16
  18. data/test/.blogs/drafts/0002-the-new-amphitheatre-is-overrated.lt3 +0 -16
  19. data/test/.blogs/drafts/0003-elixir-conf-coming-up.lt3 +0 -17
  20. data/test/.blogs/drafts/0004-does-indie-still-matter.lt3 +0 -16
  21. data/test/.blogs/drafts/0005-the-genius-of-scenic.lt3 +0 -16
  22. data/test/.blogs/drafts/0006-the-future-of-coding.lt3 +0 -16
  23. data/test/.blogs/drafts/0007-the-graffiti-wall.lt3 +0 -17
  24. data/test/.blogs/drafts/0008-the-waller-creek-project.lt3 +0 -16
  25. data/test/.blogs/drafts/0009-life-on-sabine-street.lt3 +0 -16
  26. data/test/.blogs/drafts/0010-remember-modest-mouse.lt3 +0 -17
  27. data/test/.blogs/sequence +0 -1
  28. data/test/.blogs/views/around_austin/last_published +0 -1
  29. data/test/.blogs/views/around_austin/posts/0001-whats-at-stubbs/0001-whats-at-stubbs.lt3 +0 -16
  30. data/test/.blogs/views/around_austin/posts/0001-whats-at-stubbs/metadata.txt +0 -6
  31. data/test/.blogs/views/around_austin/posts/0001-whats-at-stubbs/teaser.txt +0 -1
  32. data/test/.blogs/views/around_austin/posts/0001-whats-at-stubbs/whats-at-stubbs.html +0 -11
  33. data/test/.blogs/views/around_austin/posts/0002-the-new-amphitheatre-is-overrated/0002-the-new-amphitheatre-is-overrated.lt3 +0 -16
  34. data/test/.blogs/views/around_austin/posts/0002-the-new-amphitheatre-is-overrated/metadata.txt +0 -6
  35. data/test/.blogs/views/around_austin/posts/0002-the-new-amphitheatre-is-overrated/teaser.txt +0 -1
  36. data/test/.blogs/views/around_austin/posts/0002-the-new-amphitheatre-is-overrated/the-new-amphitheatre-is-overrated.html +0 -11
  37. data/test/.blogs/views/around_austin/posts/0007-the-graffiti-wall/0007-the-graffiti-wall.lt3 +0 -17
  38. data/test/.blogs/views/around_austin/posts/0007-the-graffiti-wall/metadata.txt +0 -6
  39. data/test/.blogs/views/around_austin/posts/0007-the-graffiti-wall/teaser.txt +0 -1
  40. data/test/.blogs/views/around_austin/posts/0007-the-graffiti-wall/the-graffiti-wall.html +0 -12
  41. data/test/.blogs/views/around_austin/posts/0008-the-waller-creek-project/0008-the-waller-creek-project.lt3 +0 -16
  42. data/test/.blogs/views/around_austin/posts/0008-the-waller-creek-project/metadata.txt +0 -6
  43. data/test/.blogs/views/around_austin/posts/0008-the-waller-creek-project/teaser.txt +0 -1
  44. data/test/.blogs/views/around_austin/posts/0008-the-waller-creek-project/the-waller-creek-project.html +0 -11
  45. data/test/.blogs/views/around_austin/posts/0009-life-on-sabine-street/0009-life-on-sabine-street.lt3 +0 -16
  46. data/test/.blogs/views/around_austin/posts/0009-life-on-sabine-street/life-on-sabine-street.html +0 -11
  47. data/test/.blogs/views/around_austin/posts/0009-life-on-sabine-street/metadata.txt +0 -6
  48. data/test/.blogs/views/around_austin/posts/0009-life-on-sabine-street/teaser.txt +0 -1
  49. data/test/.blogs/views/around_austin/publish +0 -5
  50. data/test/.blogs/views/around_austin/remote/etc/blog.css +0 -34
  51. data/test/.blogs/views/around_austin/remote/etc/blog.css.lt3 +0 -36
  52. data/test/.blogs/views/around_austin/remote/etc/externals.lt3 +0 -19
  53. data/test/.blogs/views/around_austin/remote/etc/favicon.ico +0 -0
  54. data/test/.blogs/views/around_austin/remote/etc/misc.js +0 -6
  55. data/test/.blogs/views/around_austin/remote/life-on-sabine-street.html +0 -10
  56. data/test/.blogs/views/around_austin/remote/permalink/life-on-sabine-street.html +0 -10
  57. data/test/.blogs/views/around_austin/remote/permalink/the-graffiti-wall.html +0 -10
  58. data/test/.blogs/views/around_austin/remote/permalink/the-new-amphitheatre-is-overrated.html +0 -50
  59. data/test/.blogs/views/around_austin/remote/permalink/the-waller-creek-project.html +0 -50
  60. data/test/.blogs/views/around_austin/remote/permalink/whats-at-stubbs.html +0 -50
  61. data/test/.blogs/views/around_austin/remote/recent.html +0 -104
  62. data/test/.blogs/views/around_austin/remote/the-graffiti-wall.html +0 -10
  63. data/test/.blogs/views/around_austin/remote/the-new-amphitheatre-is-overrated.html +0 -50
  64. data/test/.blogs/views/around_austin/remote/the-waller-creek-project.html +0 -50
  65. data/test/.blogs/views/around_austin/remote/whats-at-stubbs.html +0 -50
  66. data/test/.blogs/views/around_austin/remote/widgets/README +0 -4
  67. data/test/.blogs/views/around_austin/remote/widgets/ad/ad.lt3 +0 -12
  68. data/test/.blogs/views/around_austin/remote/widgets/calendar/calendar.lt3 +0 -6
  69. data/test/.blogs/views/around_austin/remote/widgets/news/list.data +0 -4
  70. data/test/.blogs/views/around_austin/remote/widgets/news/news.lt3 +0 -3
  71. data/test/.blogs/views/around_austin/remote/widgets/pages/README +0 -2
  72. data/test/.blogs/views/around_austin/remote/widgets/pages/disclaim.lt3 +0 -6
  73. data/test/.blogs/views/around_austin/remote/widgets/pages/faq.lt3 +0 -6
  74. data/test/.blogs/views/around_austin/remote/widgets/pages/generated.lt3 +0 -4
  75. data/test/.blogs/views/around_austin/remote/widgets/pages/lifestory.lt3 +0 -6
  76. data/test/.blogs/views/around_austin/remote/widgets/pages/like-dislike.lt3 +0 -6
  77. data/test/.blogs/views/around_austin/remote/widgets/pages/list.data +0 -4
  78. data/test/.blogs/views/around_austin/remote/widgets/pages/main.html +0 -9
  79. data/test/.blogs/views/around_austin/remote/widgets/pages/main.lt3 +0 -18
  80. data/test/.blogs/views/around_austin/remote/widgets/tag-cloud/tag-cloud.lt3 +0 -12
  81. data/test/.blogs/views/around_austin/staging/0001-whats-at-stubbs.lt3 +0 -16
  82. data/test/.blogs/views/around_austin/staging/0002-the-new-amphitheatre-is-overrated.lt3 +0 -16
  83. data/test/.blogs/views/around_austin/staging/0007-the-graffiti-wall.lt3 +0 -17
  84. data/test/.blogs/views/around_austin/staging/0008-the-waller-creek-project.lt3 +0 -16
  85. data/test/.blogs/views/around_austin/staging/0009-life-on-sabine-street.lt3 +0 -16
  86. data/test/.blogs/views/around_austin/staging/README +0 -59
  87. data/test/.blogs/views/around_austin/staging/blog/generate.lt3 +0 -17
  88. data/test/.blogs/views/around_austin/staging/blog/head.lt3 +0 -9
  89. data/test/.blogs/views/around_austin/staging/blog/index.lt3 +0 -6
  90. data/test/.blogs/views/around_austin/staging/blog/post_entry.lt3 +0 -19
  91. data/test/.blogs/views/around_austin/staging/etc/blog.css +0 -34
  92. data/test/.blogs/views/around_austin/staging/etc/blog.css.lt3 +0 -36
  93. data/test/.blogs/views/around_austin/staging/etc/externals.lt3 +0 -19
  94. data/test/.blogs/views/around_austin/staging/etc/favicon.ico +0 -0
  95. data/test/.blogs/views/around_austin/staging/etc/misc.js +0 -6
  96. data/test/.blogs/views/around_austin/staging/global.lt3 +0 -22
  97. data/test/.blogs/views/around_austin/staging/life-on-sabine-street.html +0 -10
  98. data/test/.blogs/views/around_austin/staging/navbar/about.html +0 -6
  99. data/test/.blogs/views/around_austin/staging/navbar/contact.html +0 -6
  100. data/test/.blogs/views/around_austin/staging/navbar/navbar.lt3 +0 -6
  101. data/test/.blogs/views/around_austin/staging/post/generate.lt3 +0 -26
  102. data/test/.blogs/views/around_austin/staging/post/head.lt3 +0 -4
  103. data/test/.blogs/views/around_austin/staging/post/index.html +0 -16
  104. data/test/.blogs/views/around_austin/staging/post/index.lt3 +0 -16
  105. data/test/.blogs/views/around_austin/staging/post/permalink.lt3 +0 -26
  106. data/test/.blogs/views/around_austin/staging/recent.html +0 -104
  107. data/test/.blogs/views/around_austin/staging/sidebar/README +0 -3
  108. data/test/.blogs/views/around_austin/staging/the-graffiti-wall.html +0 -10
  109. data/test/.blogs/views/around_austin/staging/the-new-amphitheatre-is-overrated.html +0 -50
  110. data/test/.blogs/views/around_austin/staging/the-waller-creek-project.html +0 -50
  111. data/test/.blogs/views/around_austin/staging/vars.lt3 +0 -2
  112. data/test/.blogs/views/around_austin/staging/whats-at-stubbs.html +0 -50
  113. data/test/.blogs/views/around_austin/staging/widgets/README +0 -4
  114. data/test/.blogs/views/around_austin/staging/widgets/ad/ad.lt3 +0 -12
  115. data/test/.blogs/views/around_austin/staging/widgets/calendar/calendar.lt3 +0 -6
  116. data/test/.blogs/views/around_austin/staging/widgets/news/list.data +0 -4
  117. data/test/.blogs/views/around_austin/staging/widgets/news/news.lt3 +0 -3
  118. data/test/.blogs/views/around_austin/staging/widgets/pages/README +0 -2
  119. data/test/.blogs/views/around_austin/staging/widgets/pages/disclaim.lt3 +0 -6
  120. data/test/.blogs/views/around_austin/staging/widgets/pages/faq.lt3 +0 -6
  121. data/test/.blogs/views/around_austin/staging/widgets/pages/generated.lt3 +0 -4
  122. data/test/.blogs/views/around_austin/staging/widgets/pages/lifestory.lt3 +0 -6
  123. data/test/.blogs/views/around_austin/staging/widgets/pages/like-dislike.lt3 +0 -6
  124. data/test/.blogs/views/around_austin/staging/widgets/pages/list.data +0 -4
  125. data/test/.blogs/views/around_austin/staging/widgets/pages/main.html +0 -9
  126. data/test/.blogs/views/around_austin/staging/widgets/pages/main.lt3 +0 -18
  127. data/test/.blogs/views/around_austin/staging/widgets/tag-cloud/tag-cloud.lt3 +0 -12
  128. data/test/.blogs/views/around_austin/themes/standard/README +0 -59
  129. data/test/.blogs/views/around_austin/themes/standard/blog/generate.lt3 +0 -17
  130. data/test/.blogs/views/around_austin/themes/standard/blog/head.lt3 +0 -9
  131. data/test/.blogs/views/around_austin/themes/standard/blog/index.lt3 +0 -6
  132. data/test/.blogs/views/around_austin/themes/standard/blog/post_entry.lt3 +0 -19
  133. data/test/.blogs/views/around_austin/themes/standard/etc/blog.css +0 -34
  134. data/test/.blogs/views/around_austin/themes/standard/etc/blog.css.lt3 +0 -36
  135. data/test/.blogs/views/around_austin/themes/standard/etc/externals.lt3 +0 -19
  136. data/test/.blogs/views/around_austin/themes/standard/etc/favicon.ico +0 -0
  137. data/test/.blogs/views/around_austin/themes/standard/etc/misc.js +0 -6
  138. data/test/.blogs/views/around_austin/themes/standard/global.lt3 +0 -22
  139. data/test/.blogs/views/around_austin/themes/standard/navbar/about.html +0 -6
  140. data/test/.blogs/views/around_austin/themes/standard/navbar/contact.html +0 -6
  141. data/test/.blogs/views/around_austin/themes/standard/navbar/navbar.lt3 +0 -6
  142. data/test/.blogs/views/around_austin/themes/standard/post/generate.lt3 +0 -26
  143. data/test/.blogs/views/around_austin/themes/standard/post/head.lt3 +0 -4
  144. data/test/.blogs/views/around_austin/themes/standard/post/index.lt3 +0 -16
  145. data/test/.blogs/views/around_austin/themes/standard/post/permalink.lt3 +0 -26
  146. data/test/.blogs/views/around_austin/themes/standard/sidebar/README +0 -3
  147. data/test/.blogs/views/around_austin/themes/standard/widgets/README +0 -4
  148. data/test/.blogs/views/around_austin/themes/standard/widgets/ad/ad.lt3 +0 -12
  149. data/test/.blogs/views/around_austin/themes/standard/widgets/calendar/calendar.lt3 +0 -6
  150. data/test/.blogs/views/around_austin/themes/standard/widgets/news/list.data +0 -4
  151. data/test/.blogs/views/around_austin/themes/standard/widgets/news/news.lt3 +0 -3
  152. data/test/.blogs/views/around_austin/themes/standard/widgets/pages/README +0 -2
  153. data/test/.blogs/views/around_austin/themes/standard/widgets/pages/disclaim.lt3 +0 -6
  154. data/test/.blogs/views/around_austin/themes/standard/widgets/pages/faq.lt3 +0 -6
  155. data/test/.blogs/views/around_austin/themes/standard/widgets/pages/generated.lt3 +0 -4
  156. data/test/.blogs/views/around_austin/themes/standard/widgets/pages/lifestory.lt3 +0 -6
  157. data/test/.blogs/views/around_austin/themes/standard/widgets/pages/like-dislike.lt3 +0 -6
  158. data/test/.blogs/views/around_austin/themes/standard/widgets/pages/list.data +0 -4
  159. data/test/.blogs/views/around_austin/themes/standard/widgets/pages/main.html +0 -9
  160. data/test/.blogs/views/around_austin/themes/standard/widgets/pages/main.lt3 +0 -18
  161. data/test/.blogs/views/around_austin/themes/standard/widgets/tag-cloud/tag-cloud.lt3 +0 -12
  162. data/test/.blogs/views/computing/last_published +0 -1
  163. data/test/.blogs/views/computing/posts/0003-elixir-conf-coming-up/0003-elixir-conf-coming-up.lt3 +0 -17
  164. data/test/.blogs/views/computing/posts/0003-elixir-conf-coming-up/elixir-conf-coming-up.html +0 -12
  165. data/test/.blogs/views/computing/posts/0003-elixir-conf-coming-up/metadata.txt +0 -6
  166. data/test/.blogs/views/computing/posts/0003-elixir-conf-coming-up/teaser.txt +0 -1
  167. data/test/.blogs/views/computing/posts/0005-the-genius-of-scenic/0005-the-genius-of-scenic.lt3 +0 -16
  168. data/test/.blogs/views/computing/posts/0005-the-genius-of-scenic/metadata.txt +0 -6
  169. data/test/.blogs/views/computing/posts/0005-the-genius-of-scenic/teaser.txt +0 -1
  170. data/test/.blogs/views/computing/posts/0005-the-genius-of-scenic/the-genius-of-scenic.html +0 -11
  171. data/test/.blogs/views/computing/posts/0006-the-future-of-coding/0006-the-future-of-coding.lt3 +0 -16
  172. data/test/.blogs/views/computing/posts/0006-the-future-of-coding/metadata.txt +0 -6
  173. data/test/.blogs/views/computing/posts/0006-the-future-of-coding/teaser.txt +0 -1
  174. data/test/.blogs/views/computing/posts/0006-the-future-of-coding/the-future-of-coding.html +0 -11
  175. data/test/.blogs/views/computing/publish +0 -5
  176. data/test/.blogs/views/computing/remote/elixir-conf-coming-up.html +0 -51
  177. data/test/.blogs/views/computing/remote/etc/blog.css +0 -34
  178. data/test/.blogs/views/computing/remote/etc/blog.css.lt3 +0 -36
  179. data/test/.blogs/views/computing/remote/etc/externals.lt3 +0 -19
  180. data/test/.blogs/views/computing/remote/etc/favicon.ico +0 -0
  181. data/test/.blogs/views/computing/remote/etc/misc.js +0 -6
  182. data/test/.blogs/views/computing/remote/permalink/elixir-conf-coming-up.html +0 -51
  183. data/test/.blogs/views/computing/remote/permalink/the-future-of-coding.html +0 -50
  184. data/test/.blogs/views/computing/remote/permalink/the-genius-of-scenic.html +0 -50
  185. data/test/.blogs/views/computing/remote/recent.html +0 -64
  186. data/test/.blogs/views/computing/remote/the-future-of-coding.html +0 -50
  187. data/test/.blogs/views/computing/remote/the-genius-of-scenic.html +0 -50
  188. data/test/.blogs/views/computing/remote/widgets/README +0 -4
  189. data/test/.blogs/views/computing/remote/widgets/ad/ad.lt3 +0 -12
  190. data/test/.blogs/views/computing/remote/widgets/calendar/calendar.lt3 +0 -6
  191. data/test/.blogs/views/computing/remote/widgets/news/list.data +0 -4
  192. data/test/.blogs/views/computing/remote/widgets/news/news.lt3 +0 -3
  193. data/test/.blogs/views/computing/remote/widgets/pages/README +0 -2
  194. data/test/.blogs/views/computing/remote/widgets/pages/disclaim.lt3 +0 -6
  195. data/test/.blogs/views/computing/remote/widgets/pages/faq.lt3 +0 -6
  196. data/test/.blogs/views/computing/remote/widgets/pages/generated.lt3 +0 -4
  197. data/test/.blogs/views/computing/remote/widgets/pages/lifestory.lt3 +0 -6
  198. data/test/.blogs/views/computing/remote/widgets/pages/like-dislike.lt3 +0 -6
  199. data/test/.blogs/views/computing/remote/widgets/pages/list.data +0 -4
  200. data/test/.blogs/views/computing/remote/widgets/pages/main.html +0 -9
  201. data/test/.blogs/views/computing/remote/widgets/pages/main.lt3 +0 -18
  202. data/test/.blogs/views/computing/remote/widgets/tag-cloud/tag-cloud.lt3 +0 -12
  203. data/test/.blogs/views/computing/staging/0003-elixir-conf-coming-up.lt3 +0 -17
  204. data/test/.blogs/views/computing/staging/0005-the-genius-of-scenic.lt3 +0 -16
  205. data/test/.blogs/views/computing/staging/0006-the-future-of-coding.lt3 +0 -16
  206. data/test/.blogs/views/computing/staging/README +0 -59
  207. data/test/.blogs/views/computing/staging/blog/generate.lt3 +0 -17
  208. data/test/.blogs/views/computing/staging/blog/head.lt3 +0 -9
  209. data/test/.blogs/views/computing/staging/blog/index.lt3 +0 -6
  210. data/test/.blogs/views/computing/staging/blog/post_entry.lt3 +0 -19
  211. data/test/.blogs/views/computing/staging/elixir-conf-coming-up.html +0 -51
  212. data/test/.blogs/views/computing/staging/etc/blog.css +0 -34
  213. data/test/.blogs/views/computing/staging/etc/blog.css.lt3 +0 -36
  214. data/test/.blogs/views/computing/staging/etc/externals.lt3 +0 -19
  215. data/test/.blogs/views/computing/staging/etc/favicon.ico +0 -0
  216. data/test/.blogs/views/computing/staging/etc/misc.js +0 -6
  217. data/test/.blogs/views/computing/staging/global.lt3 +0 -22
  218. data/test/.blogs/views/computing/staging/navbar/about.html +0 -6
  219. data/test/.blogs/views/computing/staging/navbar/contact.html +0 -6
  220. data/test/.blogs/views/computing/staging/navbar/navbar.lt3 +0 -6
  221. data/test/.blogs/views/computing/staging/post/generate.lt3 +0 -26
  222. data/test/.blogs/views/computing/staging/post/head.lt3 +0 -4
  223. data/test/.blogs/views/computing/staging/post/index.html +0 -16
  224. data/test/.blogs/views/computing/staging/post/index.lt3 +0 -16
  225. data/test/.blogs/views/computing/staging/post/permalink.lt3 +0 -26
  226. data/test/.blogs/views/computing/staging/recent.html +0 -64
  227. data/test/.blogs/views/computing/staging/sidebar/README +0 -3
  228. data/test/.blogs/views/computing/staging/the-future-of-coding.html +0 -50
  229. data/test/.blogs/views/computing/staging/the-genius-of-scenic.html +0 -50
  230. data/test/.blogs/views/computing/staging/vars.lt3 +0 -2
  231. data/test/.blogs/views/computing/staging/widgets/README +0 -4
  232. data/test/.blogs/views/computing/staging/widgets/ad/ad.lt3 +0 -12
  233. data/test/.blogs/views/computing/staging/widgets/calendar/calendar.lt3 +0 -6
  234. data/test/.blogs/views/computing/staging/widgets/news/list.data +0 -4
  235. data/test/.blogs/views/computing/staging/widgets/news/news.lt3 +0 -3
  236. data/test/.blogs/views/computing/staging/widgets/pages/README +0 -2
  237. data/test/.blogs/views/computing/staging/widgets/pages/disclaim.lt3 +0 -6
  238. data/test/.blogs/views/computing/staging/widgets/pages/faq.lt3 +0 -6
  239. data/test/.blogs/views/computing/staging/widgets/pages/generated.lt3 +0 -4
  240. data/test/.blogs/views/computing/staging/widgets/pages/lifestory.lt3 +0 -6
  241. data/test/.blogs/views/computing/staging/widgets/pages/like-dislike.lt3 +0 -6
  242. data/test/.blogs/views/computing/staging/widgets/pages/list.data +0 -4
  243. data/test/.blogs/views/computing/staging/widgets/pages/main.html +0 -9
  244. data/test/.blogs/views/computing/staging/widgets/pages/main.lt3 +0 -18
  245. data/test/.blogs/views/computing/staging/widgets/tag-cloud/tag-cloud.lt3 +0 -12
  246. data/test/.blogs/views/computing/themes/standard/README +0 -59
  247. data/test/.blogs/views/computing/themes/standard/blog/generate.lt3 +0 -17
  248. data/test/.blogs/views/computing/themes/standard/blog/head.lt3 +0 -9
  249. data/test/.blogs/views/computing/themes/standard/blog/index.lt3 +0 -6
  250. data/test/.blogs/views/computing/themes/standard/blog/post_entry.lt3 +0 -19
  251. data/test/.blogs/views/computing/themes/standard/etc/blog.css +0 -34
  252. data/test/.blogs/views/computing/themes/standard/etc/blog.css.lt3 +0 -36
  253. data/test/.blogs/views/computing/themes/standard/etc/externals.lt3 +0 -19
  254. data/test/.blogs/views/computing/themes/standard/etc/favicon.ico +0 -0
  255. data/test/.blogs/views/computing/themes/standard/etc/misc.js +0 -6
  256. data/test/.blogs/views/computing/themes/standard/global.lt3 +0 -22
  257. data/test/.blogs/views/computing/themes/standard/navbar/about.html +0 -6
  258. data/test/.blogs/views/computing/themes/standard/navbar/contact.html +0 -6
  259. data/test/.blogs/views/computing/themes/standard/navbar/navbar.lt3 +0 -6
  260. data/test/.blogs/views/computing/themes/standard/post/generate.lt3 +0 -26
  261. data/test/.blogs/views/computing/themes/standard/post/head.lt3 +0 -4
  262. data/test/.blogs/views/computing/themes/standard/post/index.lt3 +0 -16
  263. data/test/.blogs/views/computing/themes/standard/post/permalink.lt3 +0 -26
  264. data/test/.blogs/views/computing/themes/standard/sidebar/README +0 -3
  265. data/test/.blogs/views/computing/themes/standard/widgets/README +0 -4
  266. data/test/.blogs/views/computing/themes/standard/widgets/ad/ad.lt3 +0 -12
  267. data/test/.blogs/views/computing/themes/standard/widgets/calendar/calendar.lt3 +0 -6
  268. data/test/.blogs/views/computing/themes/standard/widgets/news/list.data +0 -4
  269. data/test/.blogs/views/computing/themes/standard/widgets/news/news.lt3 +0 -3
  270. data/test/.blogs/views/computing/themes/standard/widgets/pages/README +0 -2
  271. data/test/.blogs/views/computing/themes/standard/widgets/pages/disclaim.lt3 +0 -6
  272. data/test/.blogs/views/computing/themes/standard/widgets/pages/faq.lt3 +0 -6
  273. data/test/.blogs/views/computing/themes/standard/widgets/pages/generated.lt3 +0 -4
  274. data/test/.blogs/views/computing/themes/standard/widgets/pages/lifestory.lt3 +0 -6
  275. data/test/.blogs/views/computing/themes/standard/widgets/pages/like-dislike.lt3 +0 -6
  276. data/test/.blogs/views/computing/themes/standard/widgets/pages/list.data +0 -4
  277. data/test/.blogs/views/computing/themes/standard/widgets/pages/main.html +0 -9
  278. data/test/.blogs/views/computing/themes/standard/widgets/pages/main.lt3 +0 -18
  279. data/test/.blogs/views/computing/themes/standard/widgets/tag-cloud/tag-cloud.lt3 +0 -12
  280. data/test/.blogs/views/music/last_published +0 -1
  281. data/test/.blogs/views/music/posts/0004-does-indie-still-matter/0004-does-indie-still-matter.lt3 +0 -16
  282. data/test/.blogs/views/music/posts/0004-does-indie-still-matter/does-indie-still-matter.html +0 -11
  283. data/test/.blogs/views/music/posts/0004-does-indie-still-matter/metadata.txt +0 -6
  284. data/test/.blogs/views/music/posts/0004-does-indie-still-matter/teaser.txt +0 -1
  285. data/test/.blogs/views/music/posts/0010-remember-modest-mouse/0010-remember-modest-mouse.lt3 +0 -17
  286. data/test/.blogs/views/music/posts/0010-remember-modest-mouse/metadata.txt +0 -6
  287. data/test/.blogs/views/music/posts/0010-remember-modest-mouse/remember-modest-mouse.html +0 -12
  288. data/test/.blogs/views/music/posts/0010-remember-modest-mouse/teaser.txt +0 -1
  289. data/test/.blogs/views/music/publish +0 -5
  290. data/test/.blogs/views/music/remote/does-indie-still-matter.html +0 -50
  291. data/test/.blogs/views/music/remote/etc/blog.css +0 -34
  292. data/test/.blogs/views/music/remote/etc/blog.css.lt3 +0 -36
  293. data/test/.blogs/views/music/remote/etc/externals.lt3 +0 -19
  294. data/test/.blogs/views/music/remote/etc/favicon.ico +0 -0
  295. data/test/.blogs/views/music/remote/etc/misc.js +0 -6
  296. data/test/.blogs/views/music/remote/permalink/does-indie-still-matter.html +0 -50
  297. data/test/.blogs/views/music/remote/permalink/remember-modest-mouse.html +0 -51
  298. data/test/.blogs/views/music/remote/recent.html +0 -44
  299. data/test/.blogs/views/music/remote/remember-modest-mouse.html +0 -51
  300. data/test/.blogs/views/music/remote/widgets/README +0 -4
  301. data/test/.blogs/views/music/remote/widgets/ad/ad.lt3 +0 -12
  302. data/test/.blogs/views/music/remote/widgets/calendar/calendar.lt3 +0 -6
  303. data/test/.blogs/views/music/remote/widgets/news/list.data +0 -4
  304. data/test/.blogs/views/music/remote/widgets/news/news.lt3 +0 -3
  305. data/test/.blogs/views/music/remote/widgets/pages/README +0 -2
  306. data/test/.blogs/views/music/remote/widgets/pages/disclaim.lt3 +0 -6
  307. data/test/.blogs/views/music/remote/widgets/pages/faq.lt3 +0 -6
  308. data/test/.blogs/views/music/remote/widgets/pages/generated.lt3 +0 -4
  309. data/test/.blogs/views/music/remote/widgets/pages/lifestory.lt3 +0 -6
  310. data/test/.blogs/views/music/remote/widgets/pages/like-dislike.lt3 +0 -6
  311. data/test/.blogs/views/music/remote/widgets/pages/list.data +0 -4
  312. data/test/.blogs/views/music/remote/widgets/pages/main.html +0 -9
  313. data/test/.blogs/views/music/remote/widgets/pages/main.lt3 +0 -18
  314. data/test/.blogs/views/music/remote/widgets/tag-cloud/tag-cloud.lt3 +0 -12
  315. data/test/.blogs/views/music/staging/0004-does-indie-still-matter.lt3 +0 -16
  316. data/test/.blogs/views/music/staging/0010-remember-modest-mouse.lt3 +0 -17
  317. data/test/.blogs/views/music/staging/README +0 -59
  318. data/test/.blogs/views/music/staging/blog/generate.lt3 +0 -17
  319. data/test/.blogs/views/music/staging/blog/head.lt3 +0 -9
  320. data/test/.blogs/views/music/staging/blog/index.lt3 +0 -6
  321. data/test/.blogs/views/music/staging/blog/post_entry.lt3 +0 -19
  322. data/test/.blogs/views/music/staging/does-indie-still-matter.html +0 -50
  323. data/test/.blogs/views/music/staging/etc/blog.css +0 -34
  324. data/test/.blogs/views/music/staging/etc/blog.css.lt3 +0 -36
  325. data/test/.blogs/views/music/staging/etc/externals.lt3 +0 -19
  326. data/test/.blogs/views/music/staging/etc/favicon.ico +0 -0
  327. data/test/.blogs/views/music/staging/etc/misc.js +0 -6
  328. data/test/.blogs/views/music/staging/global.lt3 +0 -22
  329. data/test/.blogs/views/music/staging/navbar/about.html +0 -6
  330. data/test/.blogs/views/music/staging/navbar/contact.html +0 -6
  331. data/test/.blogs/views/music/staging/navbar/navbar.lt3 +0 -6
  332. data/test/.blogs/views/music/staging/post/generate.lt3 +0 -26
  333. data/test/.blogs/views/music/staging/post/head.lt3 +0 -4
  334. data/test/.blogs/views/music/staging/post/index.html +0 -17
  335. data/test/.blogs/views/music/staging/post/index.lt3 +0 -16
  336. data/test/.blogs/views/music/staging/post/permalink.lt3 +0 -26
  337. data/test/.blogs/views/music/staging/recent.html +0 -44
  338. data/test/.blogs/views/music/staging/remember-modest-mouse.html +0 -51
  339. data/test/.blogs/views/music/staging/sidebar/README +0 -3
  340. data/test/.blogs/views/music/staging/vars.lt3 +0 -2
  341. data/test/.blogs/views/music/staging/widgets/README +0 -4
  342. data/test/.blogs/views/music/staging/widgets/ad/ad.lt3 +0 -12
  343. data/test/.blogs/views/music/staging/widgets/calendar/calendar.lt3 +0 -6
  344. data/test/.blogs/views/music/staging/widgets/news/list.data +0 -4
  345. data/test/.blogs/views/music/staging/widgets/news/news.lt3 +0 -3
  346. data/test/.blogs/views/music/staging/widgets/pages/README +0 -2
  347. data/test/.blogs/views/music/staging/widgets/pages/disclaim.lt3 +0 -6
  348. data/test/.blogs/views/music/staging/widgets/pages/faq.lt3 +0 -6
  349. data/test/.blogs/views/music/staging/widgets/pages/generated.lt3 +0 -4
  350. data/test/.blogs/views/music/staging/widgets/pages/lifestory.lt3 +0 -6
  351. data/test/.blogs/views/music/staging/widgets/pages/like-dislike.lt3 +0 -6
  352. data/test/.blogs/views/music/staging/widgets/pages/list.data +0 -4
  353. data/test/.blogs/views/music/staging/widgets/pages/main.html +0 -9
  354. data/test/.blogs/views/music/staging/widgets/pages/main.lt3 +0 -18
  355. data/test/.blogs/views/music/staging/widgets/tag-cloud/tag-cloud.lt3 +0 -12
  356. data/test/.blogs/views/music/themes/standard/README +0 -59
  357. data/test/.blogs/views/music/themes/standard/blog/generate.lt3 +0 -17
  358. data/test/.blogs/views/music/themes/standard/blog/head.lt3 +0 -9
  359. data/test/.blogs/views/music/themes/standard/blog/index.lt3 +0 -6
  360. data/test/.blogs/views/music/themes/standard/blog/post_entry.lt3 +0 -19
  361. data/test/.blogs/views/music/themes/standard/etc/blog.css +0 -34
  362. data/test/.blogs/views/music/themes/standard/etc/blog.css.lt3 +0 -36
  363. data/test/.blogs/views/music/themes/standard/etc/externals.lt3 +0 -19
  364. data/test/.blogs/views/music/themes/standard/etc/favicon.ico +0 -0
  365. data/test/.blogs/views/music/themes/standard/etc/misc.js +0 -6
  366. data/test/.blogs/views/music/themes/standard/global.lt3 +0 -22
  367. data/test/.blogs/views/music/themes/standard/navbar/about.html +0 -6
  368. data/test/.blogs/views/music/themes/standard/navbar/contact.html +0 -6
  369. data/test/.blogs/views/music/themes/standard/navbar/navbar.lt3 +0 -6
  370. data/test/.blogs/views/music/themes/standard/post/generate.lt3 +0 -26
  371. data/test/.blogs/views/music/themes/standard/post/head.lt3 +0 -4
  372. data/test/.blogs/views/music/themes/standard/post/index.lt3 +0 -16
  373. data/test/.blogs/views/music/themes/standard/post/permalink.lt3 +0 -26
  374. data/test/.blogs/views/music/themes/standard/sidebar/README +0 -3
  375. data/test/.blogs/views/music/themes/standard/widgets/README +0 -4
  376. data/test/.blogs/views/music/themes/standard/widgets/ad/ad.lt3 +0 -12
  377. data/test/.blogs/views/music/themes/standard/widgets/calendar/calendar.lt3 +0 -6
  378. data/test/.blogs/views/music/themes/standard/widgets/news/list.data +0 -4
  379. data/test/.blogs/views/music/themes/standard/widgets/news/news.lt3 +0 -3
  380. data/test/.blogs/views/music/themes/standard/widgets/pages/README +0 -2
  381. data/test/.blogs/views/music/themes/standard/widgets/pages/disclaim.lt3 +0 -6
  382. data/test/.blogs/views/music/themes/standard/widgets/pages/faq.lt3 +0 -6
  383. data/test/.blogs/views/music/themes/standard/widgets/pages/generated.lt3 +0 -4
  384. data/test/.blogs/views/music/themes/standard/widgets/pages/lifestory.lt3 +0 -6
  385. data/test/.blogs/views/music/themes/standard/widgets/pages/like-dislike.lt3 +0 -6
  386. data/test/.blogs/views/music/themes/standard/widgets/pages/list.data +0 -4
  387. data/test/.blogs/views/music/themes/standard/widgets/pages/main.html +0 -9
  388. data/test/.blogs/views/music/themes/standard/widgets/pages/main.lt3 +0 -18
  389. data/test/.blogs/views/music/themes/standard/widgets/tag-cloud/tag-cloud.lt3 +0 -12
  390. data/test/.blogs/views/test_view/last_published +0 -1
  391. data/test/.blogs/views/test_view/publish +0 -5
  392. data/test/.blogs/views/test_view/remote/etc/blog.css +0 -34
  393. data/test/.blogs/views/test_view/remote/etc/blog.css.lt3 +0 -36
  394. data/test/.blogs/views/test_view/remote/etc/externals.lt3 +0 -19
  395. data/test/.blogs/views/test_view/remote/etc/favicon.ico +0 -0
  396. data/test/.blogs/views/test_view/remote/etc/misc.js +0 -6
  397. data/test/.blogs/views/test_view/remote/widgets/README +0 -4
  398. data/test/.blogs/views/test_view/remote/widgets/ad/ad.lt3 +0 -12
  399. data/test/.blogs/views/test_view/remote/widgets/calendar/calendar.lt3 +0 -6
  400. data/test/.blogs/views/test_view/remote/widgets/news/list.data +0 -4
  401. data/test/.blogs/views/test_view/remote/widgets/news/news.lt3 +0 -3
  402. data/test/.blogs/views/test_view/remote/widgets/pages/README +0 -2
  403. data/test/.blogs/views/test_view/remote/widgets/pages/disclaim.lt3 +0 -6
  404. data/test/.blogs/views/test_view/remote/widgets/pages/faq.lt3 +0 -6
  405. data/test/.blogs/views/test_view/remote/widgets/pages/generated.lt3 +0 -4
  406. data/test/.blogs/views/test_view/remote/widgets/pages/lifestory.lt3 +0 -6
  407. data/test/.blogs/views/test_view/remote/widgets/pages/like-dislike.lt3 +0 -6
  408. data/test/.blogs/views/test_view/remote/widgets/pages/list.data +0 -4
  409. data/test/.blogs/views/test_view/remote/widgets/pages/main.html +0 -9
  410. data/test/.blogs/views/test_view/remote/widgets/pages/main.lt3 +0 -18
  411. data/test/.blogs/views/test_view/remote/widgets/tag-cloud/tag-cloud.lt3 +0 -12
  412. data/test/.blogs/views/test_view/staging/README +0 -59
  413. data/test/.blogs/views/test_view/staging/blog/generate.lt3 +0 -17
  414. data/test/.blogs/views/test_view/staging/blog/head.lt3 +0 -9
  415. data/test/.blogs/views/test_view/staging/blog/index.lt3 +0 -6
  416. data/test/.blogs/views/test_view/staging/blog/post_entry.lt3 +0 -19
  417. data/test/.blogs/views/test_view/staging/etc/blog.css +0 -34
  418. data/test/.blogs/views/test_view/staging/etc/blog.css.lt3 +0 -36
  419. data/test/.blogs/views/test_view/staging/etc/externals.lt3 +0 -19
  420. data/test/.blogs/views/test_view/staging/etc/favicon.ico +0 -0
  421. data/test/.blogs/views/test_view/staging/etc/misc.js +0 -6
  422. data/test/.blogs/views/test_view/staging/global.lt3 +0 -22
  423. data/test/.blogs/views/test_view/staging/navbar/about.html +0 -6
  424. data/test/.blogs/views/test_view/staging/navbar/contact.html +0 -6
  425. data/test/.blogs/views/test_view/staging/navbar/navbar.lt3 +0 -6
  426. data/test/.blogs/views/test_view/staging/post/generate.lt3 +0 -26
  427. data/test/.blogs/views/test_view/staging/post/head.lt3 +0 -4
  428. data/test/.blogs/views/test_view/staging/post/index.lt3 +0 -16
  429. data/test/.blogs/views/test_view/staging/post/permalink.lt3 +0 -26
  430. data/test/.blogs/views/test_view/staging/sidebar/README +0 -3
  431. data/test/.blogs/views/test_view/staging/widgets/README +0 -4
  432. data/test/.blogs/views/test_view/staging/widgets/ad/ad.lt3 +0 -12
  433. data/test/.blogs/views/test_view/staging/widgets/calendar/calendar.lt3 +0 -6
  434. data/test/.blogs/views/test_view/staging/widgets/news/list.data +0 -4
  435. data/test/.blogs/views/test_view/staging/widgets/news/news.lt3 +0 -3
  436. data/test/.blogs/views/test_view/staging/widgets/pages/README +0 -2
  437. data/test/.blogs/views/test_view/staging/widgets/pages/disclaim.lt3 +0 -6
  438. data/test/.blogs/views/test_view/staging/widgets/pages/faq.lt3 +0 -6
  439. data/test/.blogs/views/test_view/staging/widgets/pages/generated.lt3 +0 -4
  440. data/test/.blogs/views/test_view/staging/widgets/pages/lifestory.lt3 +0 -6
  441. data/test/.blogs/views/test_view/staging/widgets/pages/like-dislike.lt3 +0 -6
  442. data/test/.blogs/views/test_view/staging/widgets/pages/list.data +0 -4
  443. data/test/.blogs/views/test_view/staging/widgets/pages/main.html +0 -9
  444. data/test/.blogs/views/test_view/staging/widgets/pages/main.lt3 +0 -18
  445. data/test/.blogs/views/test_view/staging/widgets/tag-cloud/tag-cloud.lt3 +0 -12
  446. data/test/.blogs/views/test_view/themes/standard/README +0 -59
  447. data/test/.blogs/views/test_view/themes/standard/blog/generate.lt3 +0 -17
  448. data/test/.blogs/views/test_view/themes/standard/blog/head.lt3 +0 -9
  449. data/test/.blogs/views/test_view/themes/standard/blog/index.lt3 +0 -6
  450. data/test/.blogs/views/test_view/themes/standard/blog/post_entry.lt3 +0 -19
  451. data/test/.blogs/views/test_view/themes/standard/etc/blog.css +0 -34
  452. data/test/.blogs/views/test_view/themes/standard/etc/blog.css.lt3 +0 -36
  453. data/test/.blogs/views/test_view/themes/standard/etc/externals.lt3 +0 -19
  454. data/test/.blogs/views/test_view/themes/standard/etc/favicon.ico +0 -0
  455. data/test/.blogs/views/test_view/themes/standard/etc/misc.js +0 -6
  456. data/test/.blogs/views/test_view/themes/standard/global.lt3 +0 -22
  457. data/test/.blogs/views/test_view/themes/standard/navbar/about.html +0 -6
  458. data/test/.blogs/views/test_view/themes/standard/navbar/contact.html +0 -6
  459. data/test/.blogs/views/test_view/themes/standard/navbar/navbar.lt3 +0 -6
  460. data/test/.blogs/views/test_view/themes/standard/post/generate.lt3 +0 -26
  461. data/test/.blogs/views/test_view/themes/standard/post/head.lt3 +0 -4
  462. data/test/.blogs/views/test_view/themes/standard/post/index.lt3 +0 -16
  463. data/test/.blogs/views/test_view/themes/standard/post/permalink.lt3 +0 -26
  464. data/test/.blogs/views/test_view/themes/standard/sidebar/README +0 -3
  465. data/test/.blogs/views/test_view/themes/standard/widgets/README +0 -4
  466. data/test/.blogs/views/test_view/themes/standard/widgets/ad/ad.lt3 +0 -12
  467. data/test/.blogs/views/test_view/themes/standard/widgets/calendar/calendar.lt3 +0 -6
  468. data/test/.blogs/views/test_view/themes/standard/widgets/news/list.data +0 -4
  469. data/test/.blogs/views/test_view/themes/standard/widgets/news/news.lt3 +0 -3
  470. data/test/.blogs/views/test_view/themes/standard/widgets/pages/README +0 -2
  471. data/test/.blogs/views/test_view/themes/standard/widgets/pages/disclaim.lt3 +0 -6
  472. data/test/.blogs/views/test_view/themes/standard/widgets/pages/faq.lt3 +0 -6
  473. data/test/.blogs/views/test_view/themes/standard/widgets/pages/generated.lt3 +0 -4
  474. data/test/.blogs/views/test_view/themes/standard/widgets/pages/lifestory.lt3 +0 -6
  475. data/test/.blogs/views/test_view/themes/standard/widgets/pages/like-dislike.lt3 +0 -6
  476. data/test/.blogs/views/test_view/themes/standard/widgets/pages/list.data +0 -4
  477. data/test/.blogs/views/test_view/themes/standard/widgets/pages/main.html +0 -9
  478. data/test/.blogs/views/test_view/themes/standard/widgets/pages/main.lt3 +0 -18
  479. data/test/.blogs/views/test_view/themes/standard/widgets/tag-cloud/tag-cloud.lt3 +0 -12
  480. data/themes/standard/README +0 -59
  481. data/themes/standard/blog/generate.lt3 +0 -17
  482. data/themes/standard/blog/head.lt3 +0 -9
  483. data/themes/standard/blog/index.lt3 +0 -5
  484. data/themes/standard/blog/post_entry.lt3 +0 -19
  485. data/themes/standard/blog/recent.lt3 +0 -2
  486. data/themes/standard/etc/blog.css.lt3 +0 -36
  487. data/themes/standard/etc/externals.lt3 +0 -19
  488. data/themes/standard/etc/favicon.ico +0 -0
  489. data/themes/standard/etc/misc.js +0 -6
  490. data/themes/standard/global.lt3 +0 -22
  491. data/themes/standard/navbar/about.html +0 -6
  492. data/themes/standard/navbar/contact.html +0 -6
  493. data/themes/standard/navbar/navbar.lt3 +0 -6
  494. data/themes/standard/post/generate.lt3 +0 -24
  495. data/themes/standard/post/head.lt3 +0 -4
  496. data/themes/standard/post/index.lt3 +0 -16
  497. data/themes/standard/post/permalink.lt3 +0 -26
  498. data/themes/standard/sidebar/README +0 -3
  499. data/themes/standard/widgets/README +0 -4
  500. data/themes/standard/widgets/ad/ad.lt3 +0 -15
  501. data/themes/standard/widgets/calendar/calendar.lt3 +0 -6
  502. data/themes/standard/widgets/news/list.data +0 -4
  503. data/themes/standard/widgets/news/news.lt3 +0 -2
  504. data/themes/standard/widgets/pages/README +0 -2
  505. data/themes/standard/widgets/pages/disclaim.html +0 -6
  506. data/themes/standard/widgets/pages/disclaim.lt3 +0 -5
  507. data/themes/standard/widgets/pages/faq.html +0 -7
  508. data/themes/standard/widgets/pages/faq.lt3 +0 -6
  509. data/themes/standard/widgets/pages/generated.lt3 +0 -4
  510. data/themes/standard/widgets/pages/lifestory.html +0 -7
  511. data/themes/standard/widgets/pages/lifestory.lt3 +0 -6
  512. data/themes/standard/widgets/pages/like-dislike.html +0 -7
  513. data/themes/standard/widgets/pages/like-dislike.lt3 +0 -6
  514. data/themes/standard/widgets/pages/list.data +0 -4
  515. data/themes/standard/widgets/pages/main.html +0 -9
  516. data/themes/standard/widgets/pages/pages.lt3 +0 -2
  517. data/themes/standard/widgets/tag-cloud/tag-cloud.lt3 +0 -12
@@ -1,757 +0,0 @@
1
- require 'ostruct'
2
- require 'pp'
3
- require 'date'
4
-
5
- require 'livetext'
6
- require 'runeblog'
7
-
8
- errfile = File.new("/tmp/liveblog.out", "w")
9
- STDERR.reopen(errfile)
10
-
11
- def init_liveblog # FIXME - a lot of this logic sucks
12
- log!(enter: __method__)
13
- here = Dir.pwd
14
- dir = here
15
- loop { dir = Dir.pwd; break if File.exist?("config"); Dir.chdir("..") }
16
- Dir.chdir(here)
17
- log!(str: "Calling RuneBlog.new")
18
- @blog = $_blog = RuneBlog.new(dir)
19
- @root = @blog.root
20
- @view = @blog.view
21
- @view_name = @blog.view.name
22
- @vdir = @blog.view.dir
23
- @version = RuneBlog::VERSION
24
- @theme = @vdir + "/themes/standard/"
25
- end
26
-
27
- # FIXME - stale? and livetext are duplicated from helpers-blog
28
-
29
- def stale?(src, dst)
30
- log!(enter: __method__, args: [src, dst])
31
- return true unless File.exist?(dst)
32
- return true if File.mtime(src) > File.mtime(dst)
33
- return false
34
- end
35
-
36
- def livetext(src, dst=nil)
37
- log!(enter: __method__, args: [src, dst])
38
- src += ".lt3" unless src.end_with?(".lt3")
39
- if dst
40
- dst += ".html" unless dst.end_with?(".html")
41
- else
42
- dst = src.sub(/.lt3$/, "")
43
- end
44
- return unless stale?(src, dst)
45
- system("livetext #{src} >#{dst}")
46
- end
47
-
48
- def post
49
- log!(enter: __method__)
50
- @meta = OpenStruct.new
51
- @meta.num = _args[0]
52
- _out " <!-- Post number #{@meta.num} -->\n "
53
- end
54
-
55
- def quote
56
- log!(enter: __method__)
57
- _passthru "<blockquote>"
58
- _passthru _body
59
- _passthru "</blockquote>"
60
- _optional_blank_line
61
- end
62
-
63
- def categories # does nothing right now
64
- log!(str: "Does nothing yet", enter: __method__)
65
- end
66
-
67
- def style
68
- log!(enter: __method__)
69
- fname = _args[0]
70
- _passthru %[<link rel="stylesheet" href="???/etc/#{fname}')">]
71
- end
72
-
73
- # Move elsewhere later!
74
-
75
- def h1; _passthru "<h1>#{@_data}</h1>"; end
76
- def h2; _passthru "<h2>#{@_data}</h2>"; end
77
- def h3; _passthru "<h3>#{@_data}</h3>"; end
78
- def h4; _passthru "<h4>#{@_data}</h4>"; end
79
- def h5; _passthru "<h5>#{@_data}</h5>"; end
80
- def h6; _passthru "<h6>#{@_data}</h6>"; end
81
-
82
- def hr; _passthru "<hr>"; end
83
-
84
- def list
85
- log!(enter: __method__)
86
- _out "<ul>"
87
- _body {|line| _out "<li>#{line}</li>" }
88
- _out "</ul>"
89
- _optional_blank_line
90
- end
91
-
92
- def list!
93
- log!(enter: __method__)
94
- _out "<ul>"
95
- lines = _body.each
96
- loop do
97
- line = lines.next
98
- line = _format(line)
99
- if line[0] == " "
100
- _out line
101
- else
102
- _out "<li>#{line}</li>"
103
- end
104
- end
105
- _out "</ul>"
106
- _optional_blank_line
107
- end
108
-
109
- def _html_body(file)
110
- log!(enter: __method__, args: [file])
111
- file.puts "<html>\n <body>"
112
- yield
113
- file.puts " </body>\n</html>"
114
- end
115
-
116
- def _write_card(cardfile, mainfile, pairs, card_title, tag, relative: true)
117
- # HTML for sidebar card
118
- log!(str: "Creating #{cardfile}.html", pwd: true)
119
- File.open("#{cardfile}.html", "w") do |f|
120
- f.puts <<-EOS
121
- <div class="card mb-3">
122
- <div class="card-body">
123
- <h5 class="card-title">
124
- <a href="javascript: void(0)"
125
- onclick="javascript:open_main('widgets/#{tag}/#{mainfile}.html')"
126
- style="text-decoration: none; color: black">#{card_title}</a>
127
- </h5>
128
- <!-- <ul class="list-group list-group-flush"> -->
129
- EOS
130
- log!(str: "Writing data pairs to #{cardfile}.html", pwd: true)
131
- top = relative ? "widgets/#{tag}/" : ""
132
- pairs.each do |file, title|
133
- f.puts <<-EOS
134
- <li class="list-group-item"> <a href="javascript: void(0)"
135
- onclick="javascript:open_main('#{top}#{file}')">#{title}</a> </li>
136
- EOS
137
- end
138
- f.puts <<-EOS
139
- <!-- </ul> -->
140
- </div>
141
- </div>
142
- EOS
143
- end
144
-
145
- def _write_main(mainfile, pairs, card_title)
146
- # HTML for main area (iframe)
147
- log!(str: "Creating #{mainfile}.html", pwd: true)
148
- File.open("#{mainfile}.html", "w") do |f|
149
- _html_body(f) do
150
- f.puts "<h1>#{card_title}</h1>"
151
- pairs.each do |file, title|
152
- f.puts %[<a style="text-decoration: none; font-size: 24px" href="#{file}">#{title}</a> <br>]
153
- end
154
- end
155
- end
156
- end
157
-
158
- def make_main_links
159
- log!(enter: __method__)
160
- # FIXME remember strings may not be safe
161
- line = _data.chomp
162
- tag, card_title = *line.split(" ", 2)
163
- cardfile, mainfile = "card-#{tag}", "main-#{tag}"
164
- input = "list.data"
165
- log!(str: "Reading #{input}", pwd: true)
166
- pairs = File.readlines(input).map {|line| line.chomp.split(",", 2) }
167
- _write_main(mainfile, pairs, card_title)
168
- widget_relative = (tag != "news") # FIXME kludge!!!
169
- _write_card(cardfile, mainfile, pairs, card_title, tag, relative: widget_relative)
170
- end
171
- log!(str: "...returning from method", pwd: true)
172
- end
173
-
174
- ### inset
175
-
176
- def inset
177
- log!(enter: __method__)
178
- lines = _body
179
- box = ""
180
- lines.each do |line|
181
- line = line.dup
182
- if line[0] == "/" # Only into inset
183
- line[0] = ' '
184
- box << line.dup + " "
185
- line.replace(" ")
186
- end
187
- if line[0] == "|" # Into inset and body
188
- line[0] = ' '
189
- box << line.dup + " "
190
- end
191
- _passthru(line)
192
- end
193
- lr = _args.first
194
- wide = _args[1] || "25"
195
- _passthru "<div style='float:#{lr}; width: #{wide}%; padding:8px; padding-right:12px; font-family:verdana'>"
196
- _passthru '<b><i>'
197
- _passthru box
198
- _passthru_noline '</i></b></div>'
199
- _optional_blank_line
200
- end
201
-
202
- def _errout(*args)
203
- log!(str: args.join(" "), enter: __method__)
204
- ::STDERR.puts *args
205
- end
206
-
207
- def _passthru(line)
208
- log!(enter: __method__, args: [line])
209
- return if line.nil?
210
- line = _format(line)
211
- _out line + "\n"
212
- _out "<p>" if line.empty? && ! @_nopara
213
- end
214
-
215
- def _passthru_noline(line)
216
- log!(enter: __method__, args: [line])
217
- return if line.nil?
218
- line = _format(line)
219
- _out line
220
- _out "<p>" if line.empty? && ! @_nopara
221
- end
222
-
223
- def title
224
- log!(enter: __method__)
225
- raise "'post' was not called" unless @meta
226
- title = @_data.chomp
227
- @meta.title = title
228
- setvar :title, title
229
- _out %[<h1 class="post-title">#{title}</h1><br>]
230
- _optional_blank_line
231
- end
232
-
233
- def pubdate
234
- log!(enter: __method__)
235
- raise "'post' was not called" unless @meta
236
- _debug "data = #@_data"
237
- # Check for discrepancy?
238
- match = /(\d{4}).(\d{2}).(\d{2})/.match @_data
239
- junk, y, m, d = match.to_a
240
- y, m, d = y.to_i, m.to_i, d.to_i
241
- @meta.date = ::Date.new(y, m, d)
242
- @meta.pubdate = "%04d-%02d-%02d" % [y, m, d]
243
- _optional_blank_line
244
- end
245
-
246
- def image # primitive so far
247
- log!(enter: __method__)
248
- _debug "img: huh? <img src=#{_args.first}></img>"
249
- fname = _args.first
250
- path = "assets/#{fname}"
251
- _out "<img src=#{path}></img>"
252
- _optional_blank_line
253
- end
254
-
255
- def tags
256
- log!(enter: __method__)
257
- raise "'post' was not called" unless @meta
258
- _debug "args = #{_args}"
259
- @meta.tags = _args.dup || []
260
- _optional_blank_line
261
- end
262
-
263
- def views
264
- log!(enter: __method__)
265
- raise "'post' was not called" unless @meta
266
- _debug "data = #{_args}"
267
- @meta.views = _args.dup
268
- _optional_blank_line
269
- end
270
-
271
- def pin
272
- log!(enter: __method__)
273
- raise "'post' was not called" unless @meta
274
- _debug "data = #{_args}"
275
- # verify only already-specified views?
276
- @meta.pinned = _args.dup
277
- _optional_blank_line
278
- end
279
-
280
- def write_post
281
- log!(enter: __method__)
282
- raise "'post' was not called" unless @meta
283
- save = Dir.pwd
284
- @postdir.gsub!(/\/\//, "/") # FIXME unneeded?
285
- Dir.mkdir(@postdir) unless Dir.exist?(@postdir) # FIXME remember assets!
286
- Dir.chdir(@postdir)
287
- @meta.views = @meta.views.join(" ") if @meta.views.is_a? Array
288
- @meta.tags = @meta.tags.join(" ") if @meta.tags.is_a? Array
289
- File.write("teaser.txt", @meta.teaser)
290
-
291
- fields = [:num, :title, :date, :pubdate, :views, :tags]
292
-
293
- fname2 = "metadata.txt"
294
- f2 = File.open(fname2, "w") do |f2|
295
- fields.each {|fld| f2.puts "#{fld}: #{@meta.send(fld)}" }
296
- end
297
- Dir.chdir(save)
298
- rescue => err
299
- puts "err = #{err}"
300
- puts err.backtrace.join("\n")
301
- end
302
-
303
- def teaser
304
- log!(enter: __method__)
305
- raise "'post' was not called" unless @meta
306
- @meta.teaser = _body_text
307
- setvar :teaser, @meta.teaser
308
- _out @meta.teaser + "\n"
309
- # FIXME
310
- end
311
-
312
- def finalize
313
- log!(enter: __method__)
314
- unless @meta
315
- puts @live.body
316
- return
317
- end
318
- if @blog.nil?
319
- return @meta
320
- end
321
-
322
- @slug = @blog.make_slug(@meta)
323
- slug_dir = @slug
324
- @postdir = @blog.view.dir + "/posts/#{slug_dir}"
325
- STDERR.puts "--- finalize: pwd = #{Dir.pwd} postdir = #@postdir"
326
- write_post
327
- @meta
328
- end
329
-
330
- $Dot = self # Clunky! for dot commands called from Functions class
331
-
332
- # Find a better way to do this?
333
-
334
- class Livetext::Functions
335
-
336
- def br(n="1")
337
- # Thought: Maybe make a way for functions to "simply" call the
338
- # dot command of the same name?? Is this trivial??
339
- n = n.empty? ? 1 : n.to_i
340
- "<br>"*n
341
- end
342
-
343
- def h1(param); "<h1>#{param}</h1>"; end
344
- def h2(param); "<h2>#{param}</h2>"; end
345
- def h3(param); "<h3>#{param}</h3>"; end
346
- def h4(param); "<h4>#{param}</h4>"; end
347
- def h5(param); "<h5>#{param}</h5>"; end
348
- def h6(param); "<h6>#{param}</h6>"; end
349
-
350
- def hr(param=nil)
351
- $Dot.hr
352
- end
353
-
354
- def image(param)
355
- "<img src='#{param}'></img>"
356
- end
357
-
358
- end
359
-
360
- ###### experimental...
361
-
362
- class Livetext::Functions
363
- def _var(name)
364
- ::Livetext::Vars[name] || "[:#{name} is undefined]"
365
- end
366
-
367
- def link
368
- file, cdata = self.class.param.split("||", 2)
369
- %[<link type="application/atom+xml" rel="alternate" href="#{_var(:host)}#{file}" title="#{_var(:title)}">]
370
- end
371
- end
372
-
373
- ###
374
-
375
- def _var(name) # FIXME scope issue!
376
- ::Livetext::Vars[name] || "[:#{name} is undefined]"
377
- end
378
-
379
- def head # Does NOT output <head> tags
380
- log!(enter: __method__)
381
- args = _args
382
- args.each do |inc|
383
- self.data = inc
384
- _include
385
- end
386
- # Depends on vars: title, desc, host
387
- defaults = {}
388
- defaults = { "charset" => %[<meta charset="utf-8">],
389
- "http-equiv" => %[<meta http-equiv="X-UA-Compatible" content="IE=edge">],
390
- "title" => %[<title>\n #{_var(:blog)} | #{_var("blog.desc")}\n </title>],
391
- "generator" => %[<meta name="generator" content="Runeblog v #@version">],
392
- "og:title" => %[<meta property="og:title" content="#{_var(:blog)}">],
393
- "og:locale" => %[<meta property="og:locale" content="#{_var(:locale)}">],
394
- "description" => %[<meta name="description" content="#{_var("blog.desc")}">],
395
- "og:description" => %[<meta property="og:description" content="#{_var("blog.desc")}">],
396
- "linkc" => %[<link rel="canonical" href="#{_var(:host)}">],
397
- "og:url" => %[<meta property="og:url" content="#{_var(:host)}">],
398
- "og:site_name" => %[<meta property="og:site_name" content="#{_var(:blog)}">],
399
- "style" => %[<link rel="stylesheet" href="etc/blog.css">],
400
- "feed" => %[<link type="application/atom+xml" rel="alternate" href="#{_var(:host)}/feed.xml" title="#{_var(:blog)}">],
401
- "favicon" => %[<link rel="shortcut icon" type="image/x-icon" href="../etc/favicon.ico">\n <link rel="apple-touch-icon" href="../etc/favicon.ico">]
402
- }
403
- result = {}
404
- lines = _body
405
- lines.each do |line|
406
- line.chomp
407
- word, remain = line.split(" ", 2)
408
- case word
409
- when "viewport"
410
- result["viewport"] = %[<meta name="viewport" content="#{remain}">]
411
- when "script" # FIXME this is broken
412
- file = remain
413
- text = File.read(file)
414
- result["script"] = Livetext.new.transform(text)
415
- when "style"
416
- result["style"] = %[<link rel="stylesheet" href="('/etc/#{remain}')">]
417
- # Later: allow other overrides
418
- when ""; break
419
- else
420
- STDERR.puts "-- got '#{word}'; old value = #{result[word].inspect}"
421
- if defaults[word]
422
- result[word] = %[<meta property="#{word}" content="#{remain}">]
423
- STDERR.puts "-- new value = #{result[word].inspect}"
424
- else
425
- puts "Unknown tag '#{word}'"
426
- end
427
- end
428
- end
429
- hash = defaults.dup.update(result) # FIXME collisions?
430
-
431
- # _out "<!-- "; _out hash.inspect; _out "--> "
432
- hash.each_value {|x| _out " " + x }
433
- _out "<body>"
434
- end
435
-
436
- ########## newer stuff...
437
-
438
- def meta
439
- log!(enter: __method__)
440
- args = _args
441
- enum = args.each
442
- str = "<meta"
443
- arg = enum.next
444
- loop do
445
- if arg.end_with?(":")
446
- str << " " << arg[0..-2] << "="
447
- a2 = enum.next
448
- str << %["#{a2}"]
449
- else
450
- STDERR.puts "=== meta error?"
451
- end
452
- arg = enum.next
453
- end
454
- str << ">"
455
- _out str
456
- end
457
-
458
- def recent_posts # side-effect
459
- log!(enter: __method__)
460
- _out %[<div class="col-lg-9 col-md-9 col-sm-9 col-xs-12">]
461
- all_teasers
462
- _out %[</div>]
463
- end
464
-
465
- def sidebar
466
- log!(enter: __method__)
467
- _out %[<div class="col-lg-3 col-md-3 col-sm-3 col-xs-12">]
468
- _args do |token|
469
- tag = token.chomp.strip.downcase
470
- # FIXME will someone please refactor this horrible code??
471
- # Think of the children!!
472
- case tag[0]
473
- when "." # Only in sidebar, special code
474
- tag = tag[1..-1]
475
- Dir.chdir("widgets/#{tag}") do
476
- name = tag + ".lt3"
477
- log!(str: "DOT About to do: livetext #{name} in #{Dir.pwd}", dir: true)
478
- livetext tag + ".lt3", "card-#{tag}"
479
- log!(str: "DOT after livetext call", pwd: true, dir: true)
480
- _include_file "card-#{tag}.html"
481
- end
482
- when ":" # Card AND main, but still special
483
- tag = tag[1..-1]
484
- Dir.chdir("widgets/#{tag}") do
485
- name = tag + ".lt3"
486
- log!(str: "COL About to do: livetext #{name} in #{Dir.pwd}", dir: true)
487
- livetext tag + ".lt3", "card-#{tag}"
488
- system("card-#{tag}.html main-#{tag}.html") # FIXME HTML will be wrong??
489
- log!(str: "COL after livetext call", pwd: true, dir: true)
490
- _include_file "card-#{tag}.html"
491
- end
492
- else
493
- Dir.chdir("widgets/#{tag}") do
494
- name = tag + ".lt3"
495
- log!(str: "NRM About to do: livetext #{name} in #{Dir.pwd}", dir: true)
496
- livetext tag + ".lt3"
497
- log!(str: "NRM after livetext call", pwd: true, dir: true)
498
- _include_file "card-#{tag}.html"
499
- end
500
- end
501
- end
502
- _out %[</div>]
503
- end
504
-
505
- def stylesheet
506
- log!(enter: __method__)
507
- lines = _body
508
- url = lines[0]
509
- integ = lines[1]
510
- cross = lines[2] || "anonymous"
511
- _out %[<link rel="stylesheet" href="#{url}" integrity="#{integ}" crossorigin="#{cross}"></link>]
512
- end
513
-
514
- def script
515
- log!(enter: __method__)
516
- lines = _body
517
- url = lines[0]
518
- integ = lines[1]
519
- cross = lines[2] || "anonymous"
520
- _out %[<script src="#{url}" integrity="#{integ}" crossorigin="#{cross}"></script>]
521
- end
522
-
523
-
524
- ### How this next bit works:
525
- ###
526
- ### all_teasers will call _find_recent_posts
527
- ###
528
- ### _find_recent_posts will search higher in the directory structure
529
- ### for where the posts are (0001, 0002, ...) NOTE: This implies you
530
- ### must be in some specific place when this code is run.
531
- ### It returns the 20 most recent posts.
532
- ###
533
- ### all_teasers will then pick a small number of posts and call _teaser
534
-
535
- ### on each one. (The code in _teaser really belongs in a small template
536
- ### somewhere.)
537
- ###
538
-
539
- def _find_recent_posts
540
- log!(enter: __method__)
541
- @vdir = _var(:FileDir).match(%r[(^.*/views/.*?)/])[1]
542
- posts = nil
543
- dir_posts = @vdir + "/posts"
544
- entries = Dir.entries(dir_posts)
545
- posts = entries.grep(/^\d\d\d\d/).map {|x| dir_posts + "/" + x }
546
- posts.select! {|x| File.directory?(x) }
547
- # directories that start with four digits
548
- posts = posts.sort {|a, b| b.to_i <=> a.to_i } # sort descending
549
- posts[0..19] # return 20 at most
550
- end
551
-
552
- def all_teasers
553
- log!(enter: __method__)
554
- open = <<-HTML
555
- <section class="posts">
556
- HTML
557
- close = <<-HTML
558
- </section>
559
- HTML
560
-
561
- text = <<-HTML
562
- <html>
563
- <head><link rel="stylesheet" href="etc/blog.css"></head>
564
- <body>
565
- HTML
566
- posts = _find_recent_posts
567
- wanted = [5, posts.size].min # estimate how many we want?
568
- enum = posts.each
569
- wanted.times do
570
- postid = File.basename(enum.next)
571
- postid = postid.to_i
572
- text << _teaser(postid) # side effect! calls _out
573
- end
574
- text << "</body></html>"
575
- File.write("recent.html", text)
576
- _out %[<iframe id="main" style="width: 100vw; height: 100vh; position: relative;" src='recent.html' width=100% frameborder="0" allowfullscreen></iframe>]
577
- end
578
-
579
- def _post_lookup(postid) # side-effect
580
- log!(enter: __method__, args: [postid])
581
- # .. = templates, ../.. = views/thisview
582
- slug = title = date = teaser_text = nil
583
-
584
- dir_posts = @vdir + "/posts"
585
- posts = Dir.entries(dir_posts).grep(/^\d\d\d\d/).map {|x| dir_posts + "/" + x }
586
- posts.select! {|x| File.directory?(x) }
587
-
588
- post = posts.select {|x| File.basename(x).to_i == postid }
589
- raise "Error: More than one post #{postid}" if post.size > 1
590
- postdir = post.first
591
- vp = RuneBlog::ViewPost.new(@blog.view, postdir)
592
- vp
593
- end
594
-
595
- def _interpolate(str, context) # FIXME move this later
596
- log!(str: "Duplicated method?", enter: __method__, args: [str, context])
597
- wrapped = "%[" + str.dup + "]" # could fail...
598
- eval(wrapped, context)
599
- end
600
-
601
- def _teaser(slug)
602
- log!(enter: __method__, args: [slug])
603
- id = slug.to_i
604
- text = nil
605
- post_entry_name = @theme + "blog/post_entry.lt3"
606
- @_post_entry ||= File.read(post_entry_name)
607
- vp = _post_lookup(id)
608
- nslug, aslug, title, date, teaser_text =
609
- vp.nslug, vp.aslug, vp.title, vp.date, vp.teaser_text
610
- path = vp.path
611
- url = "#{path}/#{aslug}.html" # Should be relative to .blogs!! FIXME
612
- date = Date.parse(date)
613
- date = date.strftime("%B %e<br>%Y")
614
- text = _interpolate(@_post_entry, binding)
615
- text
616
- end
617
-
618
- def _card_generic(card_title:, middle:, extra: "")
619
- log!(enter: __method__, args: [card_title, middle, extra])
620
- front = <<-HTML
621
- <div class="card #{extra} mb-3">
622
- <div class="card-body">
623
- <h5 class="card-title">#{card_title}</h5>
624
- HTML
625
-
626
- tail = <<-HTML
627
- </div>
628
- </div>
629
- HTML
630
- text = front + middle + tail
631
- _out text + "\n "
632
- end
633
-
634
- def card_iframe
635
- log!(enter: __method__)
636
- title, lines = _data, _body
637
- lines.map!(&:chomp)
638
- url = lines[0].chomp
639
- stuff = lines[1..-1].join(" ") # FIXME later
640
- middle = <<-HTML
641
- <iframe src="#{url}" #{stuff}
642
- style="border: 0" #{stuff}
643
- frameborder="0" scrolling="no">
644
- </iframe>
645
- HTML
646
-
647
- _card_generic(card_title: title, middle: middle, extra: "bg-dark text-white")
648
- end
649
-
650
- def _main(url)
651
- log!(enter: __method__, args: [url])
652
- %[href="javascript: void(0)" onclick="javascript:open_main('#{url}')"]
653
- end
654
-
655
- def card1
656
- log!(enter: __method__)
657
- title, lines = _data, _body
658
- lines.map!(&:chomp)
659
-
660
- card_text = lines[0]
661
- url, classname, cdata = lines[1].split(",", 4)
662
- main = _main(url)
663
-
664
- middle = <<-HTML
665
- <p class="card-text">#{card_text}</p>
666
- <a #{main} class="#{classname}">#{cdata}</a>
667
- HTML
668
-
669
- _card_generic(card_title: title, middle: middle, extra: "bg-dark text-white")
670
- end
671
-
672
- def card2
673
- log!(enter: __method__)
674
- str = _data
675
- file, card_title = str.chomp.split(" ", 2)
676
- card_title = %[<a #{_main(file)} style="text-decoration: none; color: black">#{card_title}</a>]
677
-
678
- # FIXME is this wrong??
679
-
680
- open = <<-HTML
681
- <div class="card mb-3">
682
- <div class="card-body">
683
- <h5 class="card-title">#{card_title}</h5>
684
- <ul class="list-group list-group-flush">
685
- HTML
686
- _out open
687
- _body do |line|
688
- url, cdata = line.chomp.split(",", 3)
689
- main = _main(url)
690
- _out %[<li class="list-group-item"><a #{main}}">#{cdata}</a> </li>]
691
- end
692
- close = %[ </ul>\n </div>\n </div>]
693
- _out close
694
- end
695
-
696
- def tag_cloud
697
- log!(enter: __method__)
698
- title = _data
699
- title = "Tag Cloud" if title.empty?
700
- open = <<-HTML
701
- <div class="card mb-3">
702
- <div class="card-body">
703
- <h5 class="card-title">#{title}</h5>
704
- HTML
705
- _out open
706
- _body do |line|
707
- line.chomp!
708
- url, classname, cdata = line.split(",", 4)
709
- main = _main(url)
710
- _out %[<a #{main} class="#{classname}">#{cdata}</a>]
711
- end
712
- close = %[ </div>\n </div>]
713
- _out close
714
- end
715
-
716
- def navbar
717
- log!(enter: __method__)
718
- title = _var(:blog)
719
-
720
- open = <<-HTML
721
- <nav class="navbar navbar-expand-lg navbar-light bg-light">
722
- <a class="navbar-brand" href="index.html">#{title}</a>
723
- <button class="navbar-toggler"
724
- type="button"
725
- data-toggle="collapse"
726
- data-target="#navbarSupportedContent"
727
- aria-controls="navbarSupportedContent"
728
- aria-expanded="false"
729
- aria-label="Toggle navigation">
730
- <span class="navbar-toggler-icon"></span>
731
- </button>
732
- <div class="collapse navbar-collapse pull-right"
733
- id="navbarSupportedContent">
734
- <ul class="navbar-nav mr-auto">
735
- HTML
736
- close = <<-HTML
737
- </ul>
738
- </div>
739
- </nav>
740
- HTML
741
-
742
- first = true
743
- _out open
744
- _body do |line|
745
- href, cdata = line.chomp.strip.split(" ", 2)
746
- main = _main(href)
747
- if first
748
- first = false
749
- _out %[<li class="nav-item active"> <a class="nav-link" href="#{href}">#{cdata}<span class="sr-only">(current)</span></a> </li>]
750
- else
751
- main = _main("navbar/#{href}")
752
- _out %[<li class="nav-item"> <a class="nav-link" #{main}>#{cdata}</a> </li>]
753
- end
754
- end
755
- _out close
756
- end
757
-