thewoolleyman-webgen 0.5.8.20090419

Sign up to get free protection for your applications and to get access to all the features.
Files changed (309) hide show
  1. data/AUTHORS +8 -0
  2. data/COPYING +10 -0
  3. data/GPL +340 -0
  4. data/Rakefile +334 -0
  5. data/THANKS +18 -0
  6. data/bin/webgen +12 -0
  7. data/data/webgen/resources.yaml +3 -0
  8. data/data/webgen/webgui/controller/main.rb +135 -0
  9. data/data/webgen/webgui/overrides/win32console.rb +0 -0
  10. data/data/webgen/webgui/public/css/jquery.autocomplete.css +50 -0
  11. data/data/webgen/webgui/public/css/ramaze_error.css +90 -0
  12. data/data/webgen/webgui/public/css/style.css +55 -0
  13. data/data/webgen/webgui/public/img/headerbg.jpg +0 -0
  14. data/data/webgen/webgui/public/img/webgen_logo.png +0 -0
  15. data/data/webgen/webgui/public/js/jquery.autocomplete.js +15 -0
  16. data/data/webgen/webgui/public/js/jquery.js +32 -0
  17. data/data/webgen/webgui/view/create_website.xhtml +22 -0
  18. data/data/webgen/webgui/view/error.xhtml +64 -0
  19. data/data/webgen/webgui/view/index.xhtml +22 -0
  20. data/data/webgen/webgui/view/manage_website.xhtml +18 -0
  21. data/data/webgen/webgui/view/page.xhtml +40 -0
  22. data/data/webgen/website_skeleton/README +10 -0
  23. data/data/webgen/website_skeleton/Rakefile +40 -0
  24. data/data/webgen/website_skeleton/config.yaml +17 -0
  25. data/data/webgen/website_skeleton/ext/init.rb +10 -0
  26. data/data/webgen/website_styles/1024px/README +13 -0
  27. data/data/webgen/website_styles/1024px/src/default.css +188 -0
  28. data/data/webgen/website_styles/1024px/src/default.template +60 -0
  29. data/data/webgen/website_styles/1024px/src/images/background.gif +0 -0
  30. data/data/webgen/website_styles/andreas00/README +13 -0
  31. data/data/webgen/website_styles/andreas00/src/default.css +290 -0
  32. data/data/webgen/website_styles/andreas00/src/default.template +60 -0
  33. data/data/webgen/website_styles/andreas00/src/images/bg.gif +0 -0
  34. data/data/webgen/website_styles/andreas00/src/images/front.jpg +0 -0
  35. data/data/webgen/website_styles/andreas00/src/images/menubg.gif +0 -0
  36. data/data/webgen/website_styles/andreas00/src/images/menubg2.gif +0 -0
  37. data/data/webgen/website_styles/andreas01/README +14 -0
  38. data/data/webgen/website_styles/andreas01/src/default.css +310 -0
  39. data/data/webgen/website_styles/andreas01/src/default.template +62 -0
  40. data/data/webgen/website_styles/andreas01/src/images/bg.gif +0 -0
  41. data/data/webgen/website_styles/andreas01/src/images/front.jpg +0 -0
  42. data/data/webgen/website_styles/andreas01/src/print.css +35 -0
  43. data/data/webgen/website_styles/andreas03/README +14 -0
  44. data/data/webgen/website_styles/andreas03/src/default.css +223 -0
  45. data/data/webgen/website_styles/andreas03/src/default.template +58 -0
  46. data/data/webgen/website_styles/andreas03/src/images/bodybg.png +0 -0
  47. data/data/webgen/website_styles/andreas03/src/images/contbg.png +0 -0
  48. data/data/webgen/website_styles/andreas03/src/images/footerbg.png +0 -0
  49. data/data/webgen/website_styles/andreas03/src/images/gradient1.png +0 -0
  50. data/data/webgen/website_styles/andreas03/src/images/gradient2.png +0 -0
  51. data/data/webgen/website_styles/andreas04/README +15 -0
  52. data/data/webgen/website_styles/andreas04/src/default.css +290 -0
  53. data/data/webgen/website_styles/andreas04/src/default.template +81 -0
  54. data/data/webgen/website_styles/andreas04/src/images/blinkarrow.gif +0 -0
  55. data/data/webgen/website_styles/andreas04/src/images/bodybg.png +0 -0
  56. data/data/webgen/website_styles/andreas04/src/images/contentbg.png +0 -0
  57. data/data/webgen/website_styles/andreas04/src/images/entrybg.png +0 -0
  58. data/data/webgen/website_styles/andreas04/src/images/flash.gif +0 -0
  59. data/data/webgen/website_styles/andreas04/src/images/flash2.gif +0 -0
  60. data/data/webgen/website_styles/andreas04/src/images/globe.gif +0 -0
  61. data/data/webgen/website_styles/andreas04/src/images/globebottom.gif +0 -0
  62. data/data/webgen/website_styles/andreas04/src/images/linkarrow.gif +0 -0
  63. data/data/webgen/website_styles/andreas04/src/images/menuhover.png +0 -0
  64. data/data/webgen/website_styles/andreas05/README +14 -0
  65. data/data/webgen/website_styles/andreas05/src/default.css +33 -0
  66. data/data/webgen/website_styles/andreas05/src/default.template +40 -0
  67. data/data/webgen/website_styles/andreas05/src/images/bodybg.gif +0 -0
  68. data/data/webgen/website_styles/andreas05/src/images/front.png +0 -0
  69. data/data/webgen/website_styles/andreas06/README +14 -0
  70. data/data/webgen/website_styles/andreas06/src/default.css +354 -0
  71. data/data/webgen/website_styles/andreas06/src/default.template +70 -0
  72. data/data/webgen/website_styles/andreas06/src/images/bodybg.gif +0 -0
  73. data/data/webgen/website_styles/andreas06/src/images/boxbg.gif +0 -0
  74. data/data/webgen/website_styles/andreas06/src/images/greypx.gif +0 -0
  75. data/data/webgen/website_styles/andreas06/src/images/header.jpg +0 -0
  76. data/data/webgen/website_styles/andreas06/src/images/innerbg.gif +0 -0
  77. data/data/webgen/website_styles/andreas06/src/images/leaves.jpg +0 -0
  78. data/data/webgen/website_styles/andreas06/src/images/tabs.gif +0 -0
  79. data/data/webgen/website_styles/andreas07/README +15 -0
  80. data/data/webgen/website_styles/andreas07/src/browserfix.css +7 -0
  81. data/data/webgen/website_styles/andreas07/src/default.css +92 -0
  82. data/data/webgen/website_styles/andreas07/src/default.template +42 -0
  83. data/data/webgen/website_styles/andreas07/src/images/bodybg.gif +0 -0
  84. data/data/webgen/website_styles/andreas07/src/images/sidebarbg.gif +0 -0
  85. data/data/webgen/website_styles/andreas08/README +14 -0
  86. data/data/webgen/website_styles/andreas08/src/default.css +224 -0
  87. data/data/webgen/website_styles/andreas08/src/default.template +51 -0
  88. data/data/webgen/website_styles/andreas09/README +14 -0
  89. data/data/webgen/website_styles/andreas09/src/default.css +308 -0
  90. data/data/webgen/website_styles/andreas09/src/default.template +68 -0
  91. data/data/webgen/website_styles/andreas09/src/images/bodybg-black.jpg +0 -0
  92. data/data/webgen/website_styles/andreas09/src/images/bodybg-green.jpg +0 -0
  93. data/data/webgen/website_styles/andreas09/src/images/bodybg-orange.jpg +0 -0
  94. data/data/webgen/website_styles/andreas09/src/images/bodybg-purple.jpg +0 -0
  95. data/data/webgen/website_styles/andreas09/src/images/bodybg-red.jpg +0 -0
  96. data/data/webgen/website_styles/andreas09/src/images/bodybg.jpg +0 -0
  97. data/data/webgen/website_styles/andreas09/src/images/footerbg.jpg +0 -0
  98. data/data/webgen/website_styles/andreas09/src/images/menuhover-black.jpg +0 -0
  99. data/data/webgen/website_styles/andreas09/src/images/menuhover-green.jpg +0 -0
  100. data/data/webgen/website_styles/andreas09/src/images/menuhover-orange.jpg +0 -0
  101. data/data/webgen/website_styles/andreas09/src/images/menuhover-purple.jpg +0 -0
  102. data/data/webgen/website_styles/andreas09/src/images/menuhover-red.jpg +0 -0
  103. data/data/webgen/website_styles/andreas09/src/images/menuhover.jpg +0 -0
  104. data/data/webgen/website_styles/simple/README +6 -0
  105. data/data/webgen/website_styles/simple/src/default.css +84 -0
  106. data/data/webgen/website_styles/simple/src/default.template +36 -0
  107. data/data/webgen/website_templates/default/README +6 -0
  108. data/data/webgen/website_templates/default/src/index.page +8 -0
  109. data/data/webgen/website_templates/project/README +5 -0
  110. data/data/webgen/website_templates/project/src/about.page +12 -0
  111. data/data/webgen/website_templates/project/src/download.page +15 -0
  112. data/data/webgen/website_templates/project/src/features.page +8 -0
  113. data/data/webgen/website_templates/project/src/index.page +9 -0
  114. data/data/webgen/website_templates/project/src/screenshots.page +18 -0
  115. data/doc/contentprocessor.template +11 -0
  116. data/doc/contentprocessor/blocks.page +129 -0
  117. data/doc/contentprocessor/builder.page +80 -0
  118. data/doc/contentprocessor/erb.page +59 -0
  119. data/doc/contentprocessor/erubis.page +46 -0
  120. data/doc/contentprocessor/fragments.page +25 -0
  121. data/doc/contentprocessor/haml.page +47 -0
  122. data/doc/contentprocessor/maruku.page +41 -0
  123. data/doc/contentprocessor/rdiscount.page +37 -0
  124. data/doc/contentprocessor/rdoc.page +36 -0
  125. data/doc/contentprocessor/redcloth.page +39 -0
  126. data/doc/contentprocessor/sass.page +31 -0
  127. data/doc/contentprocessor/tags.page +73 -0
  128. data/doc/extensions.metainfo +29 -0
  129. data/doc/extensions.page +16 -0
  130. data/doc/extensions.template +17 -0
  131. data/doc/faq.page +219 -0
  132. data/doc/getting_started.page +135 -0
  133. data/doc/index.page +65 -0
  134. data/doc/manual.page +589 -0
  135. data/doc/reference_configuration.page +959 -0
  136. data/doc/reference_metainfo.page +222 -0
  137. data/doc/source/filesystem.page +39 -0
  138. data/doc/source/tararchive.page +40 -0
  139. data/doc/sourcehandler.template +21 -0
  140. data/doc/sourcehandler/copy.page +19 -0
  141. data/doc/sourcehandler/directory.page +27 -0
  142. data/doc/sourcehandler/feed.page +105 -0
  143. data/doc/sourcehandler/metainfo.page +41 -0
  144. data/doc/sourcehandler/page.page +14 -0
  145. data/doc/sourcehandler/sitemap.page +46 -0
  146. data/doc/sourcehandler/template.page +45 -0
  147. data/doc/sourcehandler/virtual.page +49 -0
  148. data/doc/tag.template +25 -0
  149. data/doc/tag/breadcrumbtrail.page +40 -0
  150. data/doc/tag/coderay.page +49 -0
  151. data/doc/tag/date.page +31 -0
  152. data/doc/tag/executecommand.page +26 -0
  153. data/doc/tag/includefile.page +32 -0
  154. data/doc/tag/langbar.page +44 -0
  155. data/doc/tag/link.page +44 -0
  156. data/doc/tag/menu.page +106 -0
  157. data/doc/tag/metainfo.page +29 -0
  158. data/doc/tag/relocatable.page +38 -0
  159. data/doc/tag/sitemap.page +31 -0
  160. data/doc/tag/tikz.page +158 -0
  161. data/doc/upgrading.page +139 -0
  162. data/doc/webgen_page_format.page +129 -0
  163. data/lib/webgen/blackboard.rb +78 -0
  164. data/lib/webgen/cache.rb +87 -0
  165. data/lib/webgen/cli.rb +124 -0
  166. data/lib/webgen/cli/apply_command.rb +64 -0
  167. data/lib/webgen/cli/create_command.rb +66 -0
  168. data/lib/webgen/cli/run_command.rb +22 -0
  169. data/lib/webgen/cli/utils.rb +88 -0
  170. data/lib/webgen/cli/webgui_command.rb +72 -0
  171. data/lib/webgen/common.rb +21 -0
  172. data/lib/webgen/common/sitemap.rb +83 -0
  173. data/lib/webgen/configuration.rb +153 -0
  174. data/lib/webgen/contentprocessor.rb +99 -0
  175. data/lib/webgen/contentprocessor/blocks.rb +60 -0
  176. data/lib/webgen/contentprocessor/builder.rb +30 -0
  177. data/lib/webgen/contentprocessor/context.rb +89 -0
  178. data/lib/webgen/contentprocessor/erb.rb +28 -0
  179. data/lib/webgen/contentprocessor/erubis.rb +40 -0
  180. data/lib/webgen/contentprocessor/fragments.rb +25 -0
  181. data/lib/webgen/contentprocessor/haml.rb +30 -0
  182. data/lib/webgen/contentprocessor/maruku.rb +20 -0
  183. data/lib/webgen/contentprocessor/rdiscount.rb +17 -0
  184. data/lib/webgen/contentprocessor/rdoc.rb +19 -0
  185. data/lib/webgen/contentprocessor/redcloth.rb +17 -0
  186. data/lib/webgen/contentprocessor/sass.rb +20 -0
  187. data/lib/webgen/contentprocessor/tags.rb +136 -0
  188. data/lib/webgen/coreext.rb +13 -0
  189. data/lib/webgen/default_config.rb +215 -0
  190. data/lib/webgen/languages.rb +589 -0
  191. data/lib/webgen/loggable.rb +25 -0
  192. data/lib/webgen/logger.rb +97 -0
  193. data/lib/webgen/node.rb +391 -0
  194. data/lib/webgen/output.rb +82 -0
  195. data/lib/webgen/output/filesystem.rb +69 -0
  196. data/lib/webgen/page.rb +153 -0
  197. data/lib/webgen/path.rb +194 -0
  198. data/lib/webgen/source.rb +54 -0
  199. data/lib/webgen/source/filesystem.rb +61 -0
  200. data/lib/webgen/source/resource.rb +44 -0
  201. data/lib/webgen/source/stacked.rb +55 -0
  202. data/lib/webgen/source/tararchive.rb +73 -0
  203. data/lib/webgen/sourcehandler.rb +226 -0
  204. data/lib/webgen/sourcehandler/base.rb +248 -0
  205. data/lib/webgen/sourcehandler/copy.rb +43 -0
  206. data/lib/webgen/sourcehandler/directory.rb +36 -0
  207. data/lib/webgen/sourcehandler/feed.rb +117 -0
  208. data/lib/webgen/sourcehandler/fragment.rb +68 -0
  209. data/lib/webgen/sourcehandler/memory.rb +43 -0
  210. data/lib/webgen/sourcehandler/metainfo.rb +128 -0
  211. data/lib/webgen/sourcehandler/page.rb +59 -0
  212. data/lib/webgen/sourcehandler/sitemap.rb +60 -0
  213. data/lib/webgen/sourcehandler/template.rb +66 -0
  214. data/lib/webgen/sourcehandler/virtual.rb +110 -0
  215. data/lib/webgen/tag.rb +27 -0
  216. data/lib/webgen/tag/base.rb +170 -0
  217. data/lib/webgen/tag/breadcrumbtrail.rb +70 -0
  218. data/lib/webgen/tag/coderay.rb +31 -0
  219. data/lib/webgen/tag/date.rb +18 -0
  220. data/lib/webgen/tag/executecommand.rb +30 -0
  221. data/lib/webgen/tag/includefile.rb +42 -0
  222. data/lib/webgen/tag/langbar.rb +52 -0
  223. data/lib/webgen/tag/link.rb +26 -0
  224. data/lib/webgen/tag/menu.rb +207 -0
  225. data/lib/webgen/tag/metainfo.rb +25 -0
  226. data/lib/webgen/tag/relocatable.rb +54 -0
  227. data/lib/webgen/tag/sitemap.rb +41 -0
  228. data/lib/webgen/tag/tikz.rb +119 -0
  229. data/lib/webgen/tree.rb +90 -0
  230. data/lib/webgen/version.rb +8 -0
  231. data/lib/webgen/webgentask.rb +152 -0
  232. data/lib/webgen/website.rb +342 -0
  233. data/lib/webgen/websiteaccess.rb +31 -0
  234. data/lib/webgen/websitemanager.rb +127 -0
  235. data/man/man1/webgen.1 +73 -0
  236. data/misc/default.css +384 -0
  237. data/misc/default.template +75 -0
  238. data/misc/htmldoc.metainfo +25 -0
  239. data/misc/htmldoc.virtual +5 -0
  240. data/misc/images/arrow.gif +0 -0
  241. data/misc/images/error.png +0 -0
  242. data/misc/images/headerbg.jpg +0 -0
  243. data/misc/images/important.png +0 -0
  244. data/misc/images/information.png +0 -0
  245. data/misc/images/quote.gif +0 -0
  246. data/misc/images/warning.png +0 -0
  247. data/setup.rb +1585 -0
  248. data/test/helper.rb +45 -0
  249. data/test/test_blackboard.rb +60 -0
  250. data/test/test_cache.rb +59 -0
  251. data/test/test_cli.rb +21 -0
  252. data/test/test_common.rb +18 -0
  253. data/test/test_common_sitemap.rb +58 -0
  254. data/test/test_configuration.rb +68 -0
  255. data/test/test_contentprocessor.rb +33 -0
  256. data/test/test_contentprocessor_blocks.rb +68 -0
  257. data/test/test_contentprocessor_builder.rb +23 -0
  258. data/test/test_contentprocessor_context.rb +40 -0
  259. data/test/test_contentprocessor_erb.rb +23 -0
  260. data/test/test_contentprocessor_erubis.rb +49 -0
  261. data/test/test_contentprocessor_fragments.rb +42 -0
  262. data/test/test_contentprocessor_haml.rb +23 -0
  263. data/test/test_contentprocessor_maruku.rb +29 -0
  264. data/test/test_contentprocessor_rdiscount.rb +17 -0
  265. data/test/test_contentprocessor_rdoc.rb +18 -0
  266. data/test/test_contentprocessor_redcloth.rb +15 -0
  267. data/test/test_contentprocessor_sass.rb +22 -0
  268. data/test/test_contentprocessor_tags.rb +99 -0
  269. data/test/test_languages.rb +67 -0
  270. data/test/test_loggable.rb +32 -0
  271. data/test/test_logger.rb +94 -0
  272. data/test/test_node.rb +367 -0
  273. data/test/test_output_filesystem.rb +60 -0
  274. data/test/test_page.rb +214 -0
  275. data/test/test_path.rb +165 -0
  276. data/test/test_source_filesystem.rb +76 -0
  277. data/test/test_source_resource.rb +28 -0
  278. data/test/test_source_stacked.rb +36 -0
  279. data/test/test_source_tararchive.rb +65 -0
  280. data/test/test_sourcehandler_base.rb +123 -0
  281. data/test/test_sourcehandler_copy.rb +47 -0
  282. data/test/test_sourcehandler_directory.rb +42 -0
  283. data/test/test_sourcehandler_feed.rb +77 -0
  284. data/test/test_sourcehandler_fragment.rb +69 -0
  285. data/test/test_sourcehandler_memory.rb +44 -0
  286. data/test/test_sourcehandler_metainfo.rb +118 -0
  287. data/test/test_sourcehandler_page.rb +65 -0
  288. data/test/test_sourcehandler_sitemap.rb +49 -0
  289. data/test/test_sourcehandler_template.rb +65 -0
  290. data/test/test_sourcehandler_virtual.rb +87 -0
  291. data/test/test_tag_base.rb +85 -0
  292. data/test/test_tag_breadcrumbtrail.rb +91 -0
  293. data/test/test_tag_coderay.rb +32 -0
  294. data/test/test_tag_date.rb +18 -0
  295. data/test/test_tag_executecommand.rb +41 -0
  296. data/test/test_tag_includefile.rb +50 -0
  297. data/test/test_tag_langbar.rb +72 -0
  298. data/test/test_tag_link.rb +69 -0
  299. data/test/test_tag_menu.rb +207 -0
  300. data/test/test_tag_metainfo.rb +19 -0
  301. data/test/test_tag_relocatable.rb +59 -0
  302. data/test/test_tag_sitemap.rb +47 -0
  303. data/test/test_tag_tikz.rb +69 -0
  304. data/test/test_tree.rb +70 -0
  305. data/test/test_webgentask.rb +23 -0
  306. data/test/test_website.rb +98 -0
  307. data/test/test_websiteaccess.rb +25 -0
  308. data/test/test_websitemanager.rb +70 -0
  309. metadata +613 -0
@@ -0,0 +1,19 @@
1
+ # -*- encoding: utf-8 -*-
2
+
3
+ module Webgen::ContentProcessor
4
+
5
+ # Converts content in RDoc markup (the native Ruby documentation format) to HTML. Needs the newer
6
+ # RDoc implementation provided as +rdoc+ gem!
7
+ class RDoc
8
+
9
+ # Convert the content in RDoc markup to HTML.
10
+ def call(context)
11
+ require 'rdoc/markup/to_html'
12
+
13
+ context.content = ::RDoc::Markup::ToHtml.new.convert(context.content)
14
+ context
15
+ end
16
+
17
+ end
18
+
19
+ end
@@ -0,0 +1,17 @@
1
+ # -*- encoding: utf-8 -*-
2
+
3
+ module Webgen::ContentProcessor
4
+
5
+ # Processes content in Textile format using the +redcloth+ library.
6
+ class RedCloth
7
+
8
+ # Convert the content in +context+ to HTML.
9
+ def call(context)
10
+ require 'redcloth'
11
+ context.content = ::RedCloth.new(context.content).to_html
12
+ context
13
+ end
14
+
15
+ end
16
+
17
+ end
@@ -0,0 +1,20 @@
1
+ # -*- encoding: utf-8 -*-
2
+
3
+ module Webgen::ContentProcessor
4
+
5
+ # Processes content in Sass markup (used for writing CSS files) using the +haml+ library.
6
+ class Sass
7
+
8
+ # Convert the content in +sass+ markup to CSS.
9
+ def call(context)
10
+ require 'sass'
11
+
12
+ context.content = ::Sass::Engine.new(context.content, :filename => context.ref_node.absolute_lcn).render
13
+ context
14
+ rescue Exception => e
15
+ raise RuntimeError, "Error converting Sass markup to CSS in <#{context.ref_node.absolute_lcn}>: #{e.message}", e.backtrace
16
+ end
17
+
18
+ end
19
+
20
+ end
@@ -0,0 +1,136 @@
1
+ # -*- encoding: utf-8 -*-
2
+
3
+ require 'yaml'
4
+ require 'strscan'
5
+ require 'webgen/tag'
6
+
7
+ module Webgen::ContentProcessor
8
+
9
+ # Processes special webgen tags to provide dynamic content.
10
+ #
11
+ # webgen tags are an easy way to add dynamically generated content to websites, for example menus
12
+ # or breadcrumb trails.
13
+ class Tags
14
+
15
+ include Webgen::WebsiteAccess
16
+ include Webgen::Loggable
17
+
18
+ def initialize #:nodoc:
19
+ @start_re = /(\\*)\{#{website.config['contentprocessor.tags.prefix']}(\w+)(::?)/
20
+ @end_re = /(\\*)\{#{website.config['contentprocessor.tags.prefix']}(\w+)\}/
21
+ end
22
+
23
+ # Replace all webgen tags in the content of +context+ with the rendered content.
24
+ def call(context)
25
+ replace_tags(context.content, context.ref_node) do |tag, param_string, body|
26
+ log(:debug) { "Replacing tag #{tag} with data '#{param_string}' and body '#{body}' in <#{context.ref_node.absolute_lcn}>" }
27
+
28
+ result = ''
29
+ processor = processor_for_tag(tag)
30
+ if !processor.nil?
31
+ processor.set_params(processor.create_tag_params(param_string, context.ref_node))
32
+ result, process_output = processor.call(tag, body, context)
33
+ processor.set_params(nil)
34
+
35
+ result = call(context.clone(:content => result)).content if process_output
36
+ end
37
+
38
+ result
39
+ end
40
+ context
41
+ end
42
+
43
+ #######
44
+ private
45
+ #######
46
+
47
+ BRACKETS_RE = /([{}])/
48
+ ProcessingStruct = Struct.new(:state, :tag, :simple_tag, :backslashes, :brackets, :start_pos, :end_pos,
49
+ :params_start_pos, :params_end_pos, :body_end_pos)
50
+
51
+ # Return the +content+ provided by +node+ with all webgen tags replaced. When a webgen tag is
52
+ # encountered by the parser, the method yields all found information and substitutes the
53
+ # returned string for the tag.
54
+ def replace_tags(content, node) #:yields: tag_name, param_string, body
55
+ scanner = StringScanner.new(content)
56
+ data = ProcessingStruct.new(:before_tag)
57
+ while true
58
+ case data.state
59
+ when :before_tag
60
+ if scanner.skip_until(@start_re)
61
+ data.state = :in_start_tag
62
+ data.backslashes = scanner[1].length
63
+ data.brackets = 1
64
+ data.tag = scanner[2]
65
+ data.simple_tag = (scanner[3] == ':')
66
+ data.params_start_pos = scanner.pos
67
+ data.start_pos = scanner.pos - scanner.matched.length
68
+ else
69
+ data.state = :done
70
+ end
71
+
72
+ when :in_start_tag
73
+ data.brackets += (scanner[1] == '{' ? 1 : -1) while data.brackets != 0 && scanner.skip_until(BRACKETS_RE)
74
+ if data.brackets != 0
75
+ log(:error) { "Unbalanced curly brackets in <#{node.absolute_lcn}>!" }
76
+ data.state = :done
77
+ else
78
+ data.params_end_pos = data.body_end_pos = data.end_pos = scanner.pos - 1
79
+ data.state = (data.simple_tag ? :process : :in_body)
80
+ end
81
+
82
+ when :process
83
+ if data.backslashes % 2 == 0
84
+ result = yield(data.tag, scanner.string[data.params_start_pos...data.params_end_pos],
85
+ scanner.string[(data.params_end_pos+1)...data.body_end_pos]).to_s
86
+ scanner.string[data.start_pos..data.end_pos] = "\\" * (data.backslashes / 2) + result
87
+ scanner.pos = data.start_pos + result.length
88
+ else
89
+ scanner.string[data.start_pos, 1 + data.backslashes / 2] = ''
90
+ scanner.pos -= 1 + data.backslashes / 2
91
+ end
92
+ data.state = :before_tag
93
+
94
+ when :in_body
95
+ while (result = scanner.skip_until(@end_re))
96
+ next unless scanner[2] == data.tag
97
+ if scanner[1].length % 2 == 1
98
+ scanner.string[(scanner.pos - scanner.matched.length), 1 + scanner[1].length / 2] = ''
99
+ scanner.pos -= 1 + scanner[1].length / 2
100
+ else
101
+ break
102
+ end
103
+ end
104
+ if result
105
+ data.state = :process
106
+ data.end_pos = scanner.pos - 1
107
+ data.body_end_pos = scanner.pos - scanner.matched.length + scanner[1].length / 2
108
+ else
109
+ log(:error) { "Invalid body part in <#{node.absolute_lcn}>!" }
110
+ data.state = :done
111
+ end
112
+
113
+ when :done
114
+ break
115
+ end
116
+ end
117
+ scanner.string
118
+ end
119
+
120
+ # Return the tag processor for +tag+ or +nil+ if +tag+ is unknown.
121
+ def processor_for_tag(tag)
122
+ map = website.config['contentprocessor.tags.map']
123
+ klass = if map.has_key?(tag)
124
+ map[tag]
125
+ elsif map.has_key?(:default)
126
+ map[:default]
127
+ else
128
+ log(:error) { "No tag processor for tag #{tag.inspect} found" }
129
+ nil
130
+ end
131
+ klass.nil? ? nil : website.cache.instance(klass)
132
+ end
133
+
134
+ end
135
+
136
+ end
@@ -0,0 +1,13 @@
1
+ # -*- encoding: utf-8 -*-
2
+
3
+ # :stopdoc:
4
+ class Array
5
+
6
+ def to_hash
7
+ h = {}
8
+ self.each {|k,v| h[k] = v}
9
+ h
10
+ end
11
+
12
+ end
13
+ # :startdoc:
@@ -0,0 +1,215 @@
1
+ # -*- encoding: utf-8 -*-
2
+
3
+ website = Webgen::WebsiteAccess.website
4
+ config = website.config
5
+
6
+ # General configuration parameters
7
+ config.website.cache([:file, 'webgen.cache'], :doc => 'The file name (or String) from/to which the cache is read/written')
8
+ config.website.lang('en', :doc => 'The default language used for the website')
9
+ config.website.link_to_current_page(false, :doc => 'Specifies whether links to the current page should be used')
10
+
11
+ # All things regarding logging
12
+ config.logger.mask(nil, :doc => 'Only show logging events which match the regexp mask')
13
+
14
+
15
+ # All things regarding resources
16
+ config.resources({}, :doc => 'A mapping from resource names to source identifiers')
17
+
18
+ resources = YAML::load(File.read(File.join(Webgen.data_dir, 'resources.yaml')))
19
+ resources.each do |res_path_template, res_name|
20
+ Dir.glob(File.join(Webgen.data_dir, res_path_template), File::FNM_CASEFOLD).each do |res_path|
21
+ substs = Hash.new {|h,k| h[k] = "$" + k }
22
+ substs.merge!({
23
+ 'basename' => File.basename(res_path),
24
+ 'basename_no_ext' => File.basename(res_path, '.*'),
25
+ 'extname' => File.extname(res_path)[1..-1],
26
+ :dirnames => File.dirname(res_path).split(File::SEPARATOR),
27
+ })
28
+ name = res_name.to_s.gsub(/\$\w+/) do |m|
29
+ if m =~ /^\$dir(\d+)$/
30
+ substs[:dirnames][-($1.to_i)]
31
+ else
32
+ substs[m[1..-1]]
33
+ end
34
+ end
35
+ config['resources'][name] = if File.directory?(res_path)
36
+ ["Webgen::Source::FileSystem", res_path]
37
+ else
38
+ ["Webgen::Source::FileSystem", File.dirname(res_path), File.basename(res_path)]
39
+ end
40
+ end
41
+ end
42
+
43
+
44
+ # All things regarding sources
45
+ config.sources [['/', "Webgen::Source::FileSystem", 'src']], :doc => 'One or more sources from which files are read, relative to website directory'
46
+
47
+ # All things regarding source handler
48
+ config.sourcehandler.patterns({
49
+ 'Webgen::SourceHandler::Copy' => ['**/*.css', '**/*.js', '**/*.html', '**/*.gif', '**/*.jpg', '**/*.png', '**/*.ico'],
50
+ 'Webgen::SourceHandler::Directory' => ['**/'],
51
+ 'Webgen::SourceHandler::Metainfo' => ['**/metainfo', '**/*.metainfo'],
52
+ 'Webgen::SourceHandler::Template' => ['**/*.template'],
53
+ 'Webgen::SourceHandler::Page' => ['**/*.page'],
54
+ 'Webgen::SourceHandler::Virtual' => ['**/virtual', '**/*.virtual'],
55
+ 'Webgen::SourceHandler::Feed' => ['**/*.feed'],
56
+ 'Webgen::SourceHandler::Sitemap' => ['**/*.sitemap']
57
+ }, :doc => 'Source handler to path pattern map')
58
+ config.sourcehandler.invoke({
59
+ 1 => ['Webgen::SourceHandler::Directory', 'Webgen::SourceHandler::Metainfo'],
60
+ 5 => ['Webgen::SourceHandler::Copy', 'Webgen::SourceHandler::Template',
61
+ 'Webgen::SourceHandler::Page', 'Webgen::SourceHandler::Feed',
62
+ 'Webgen::SourceHandler::Sitemap'],
63
+ 9 => ['Webgen::SourceHandler::Virtual']
64
+ }, :doc => 'All source handlers listed here are used by webgen and invoked according to their priority setting')
65
+ config.sourcehandler.casefold(true, :doc => 'Specifies whether path are considered to be case-sensitive')
66
+ config.sourcehandler.use_hidden_files(false, :doc => 'Specifies whether hidden files (those starting with a dot) are used')
67
+ config.sourcehandler.ignore(['**/*~', '**/.svn/**'], :doc => 'Path patterns that should be ignored')
68
+ config.sourcehandler.default_lang_in_output_path(false, :doc => 'Specifies whether output paths in the default language should have the language in the name')
69
+
70
+ config.sourcehandler.default_meta_info({
71
+ :all => {
72
+ 'output_path' => 'standard',
73
+ 'output_path_style' => [:parent, :cnbase, ['.', :lang], :ext]
74
+ },
75
+ 'Webgen::SourceHandler::Copy' => {
76
+ 'kind' => 'asset'
77
+ },
78
+ 'Webgen::SourceHandler::Directory' => {
79
+ 'index_path' => 'index.html',
80
+ 'kind' => 'directory'
81
+ },
82
+ 'Webgen::SourceHandler::Page' => {
83
+ 'kind' => 'page',
84
+ 'fragments_in_menu' => true,
85
+ 'blocks' => {'default' => {'pipeline' => 'erb,tags,maruku,blocks,fragments'}}
86
+ },
87
+ 'Webgen::SourceHandler::Fragment' => {
88
+ 'kind' => 'fragment'
89
+ },
90
+ 'Webgen::SourceHandler::Template' => {
91
+ 'blocks' => {'default' => {'pipeline' => 'erb,tags,blocks'}}
92
+ },
93
+ 'Webgen::SourceHandler::Metainfo' => {
94
+ 'blocks' => {1 => {'name' => 'paths'}, 2 => {'name' => 'alcn'}}
95
+ },
96
+ 'Webgen::SourceHandler::Feed' => {
97
+ 'rss' => true,
98
+ 'atom' => true
99
+ },
100
+ 'Webgen::SourceHandler::Sitemap' => {
101
+ 'default_priority' => 0.5,
102
+ 'default_change_freq' => 'weekly',
103
+ 'common.sitemap.any_lang' => true
104
+ }
105
+ }, :doc => "Default meta information for all nodes and for nodes belonging to a specific source handler")
106
+
107
+ config.sourcehandler.template.default_template('default.template', :doc => 'The name of the default template file of a directory')
108
+
109
+ website.autoload_service(:templates_for_node, 'Webgen::SourceHandler::Template')
110
+
111
+ website.autoload_service(:create_fragment_nodes, 'Webgen::SourceHandler::Fragment')
112
+ website.autoload_service(:parse_html_headers, 'Webgen::SourceHandler::Fragment')
113
+
114
+
115
+ # All things regarding output
116
+ config.output ["Webgen::Output::FileSystem", 'out'], :doc => 'The class which is used to output the generated paths.'
117
+
118
+ Webgen::WebsiteAccess.website.blackboard.add_service(:output_instance, Webgen::Output.method(:instance))
119
+
120
+
121
+ # All things regarding content processors
122
+ config.contentprocessor.map({
123
+ 'markdown' => 'Webgen::ContentProcessor::Maruku',
124
+ 'maruku' => 'Webgen::ContentProcessor::Maruku',
125
+ 'textile' => 'Webgen::ContentProcessor::RedCloth',
126
+ 'redcloth' => 'Webgen::ContentProcessor::RedCloth',
127
+ 'tags' => 'Webgen::ContentProcessor::Tags',
128
+ 'blocks' => 'Webgen::ContentProcessor::Blocks',
129
+ 'erb' => 'Webgen::ContentProcessor::Erb',
130
+ 'haml' => 'Webgen::ContentProcessor::Haml',
131
+ 'sass' => 'Webgen::ContentProcessor::Sass',
132
+ 'rdoc' => 'Webgen::ContentProcessor::RDoc',
133
+ 'builder' => 'Webgen::ContentProcessor::Builder',
134
+ 'erubis' => 'Webgen::ContentProcessor::Erubis',
135
+ 'rdiscount' => 'Webgen::ContentProcessor::RDiscount',
136
+ 'fragments' => 'Webgen::ContentProcessor::Fragments',
137
+ }, :doc => 'Content processor name to class map')
138
+
139
+ Webgen::WebsiteAccess.website.blackboard.add_service(:content_processor_names, Webgen::ContentProcessor.method(:list))
140
+ Webgen::WebsiteAccess.website.blackboard.add_service(:content_processor, Webgen::ContentProcessor.method(:for_name))
141
+
142
+ # All things regarding tags
143
+ config.contentprocessor.tags.prefix('', :doc => 'The prefix used for tag names to avoid name clashes when another content processor uses similar markup.')
144
+ config.contentprocessor.tags.map({
145
+ 'relocatable' => 'Webgen::Tag::Relocatable',
146
+ 'menu' => 'Webgen::Tag::Menu',
147
+ 'breadcrumb_trail' => 'Webgen::Tag::BreadcrumbTrail',
148
+ 'langbar' => 'Webgen::Tag::Langbar',
149
+ 'include_file' => 'Webgen::Tag::IncludeFile',
150
+ 'execute_cmd' => 'Webgen::Tag::ExecuteCommand',
151
+ 'coderay' => 'Webgen::Tag::Coderay',
152
+ 'date' => 'Webgen::Tag::Date',
153
+ 'sitemap' => 'Webgen::Tag::Sitemap',
154
+ 'tikz' => 'Webgen::Tag::TikZ',
155
+ 'link' => 'Webgen::Tag::Link',
156
+ :default => 'Webgen::Tag::Metainfo'
157
+ }, :doc => 'Tag processor name to class map')
158
+
159
+ config.contentprocessor.erubis.use_pi(false, :doc => 'Specify whether processing instructions should be used')
160
+ config.contentprocessor.erubis.options({}, :doc => 'A hash of additional options')
161
+
162
+ config.tag.relocatable.path(nil, :doc => 'The path which should be made relocatable', :mandatory => 'default')
163
+
164
+ config.tag.menu.start_level(1, :doc => 'The level at which the menu starts.')
165
+ config.tag.menu.min_levels(1, :doc => 'The minimum number of menu levels that should always be shown.')
166
+ config.tag.menu.max_levels(3, :doc => 'The maximum number of menu levels that should be shown.')
167
+ config.tag.menu.show_current_subtree_only(true, :doc => 'Specifies whether only the current subtree should be shown.')
168
+ config.tag.menu.used_nodes('all', :doc => 'Specifies the kind of nodes that should be used: all, files, or fragments')
169
+ config.tag.menu.nested(true, :doc => 'Specifies whether a nested menu list should be generated.')
170
+
171
+ config.tag.breadcrumbtrail.separator(' / ', :doc => 'Separates the hierachy entries from each other.')
172
+ config.tag.breadcrumbtrail.omit_index_path(false, :doc => 'Omits the last path component if it is an index path.')
173
+ config.tag.breadcrumbtrail.start_level(0, :doc => 'The level at which the breadcrumb trail starts.')
174
+ config.tag.breadcrumbtrail.end_level(-1, :doc => 'The level at which the breadcrumb trail ends.')
175
+
176
+ config.tag.langbar.separator(' | ', :doc => 'Separates the languages from each other.')
177
+ config.tag.langbar.show_single_lang(true, :doc => 'Should the link be shown although the page is only available in one language?')
178
+ config.tag.langbar.show_own_lang(true, :doc => 'Should the link to the currently displayed language page be shown?')
179
+ config.tag.langbar.lang_names({}, :doc => 'A map from language code to language names')
180
+ config.tag.langbar.process_output(false, :doc => 'The content of the language bar will be scanned for tags if true.')
181
+
182
+ config.tag.includefile.filename(nil, :doc => 'The name of the file which should be included (relative to the website).', :mandatory => 'default')
183
+ config.tag.includefile.process_output(true, :doc => 'The file content will be scanned for tags if true.')
184
+ config.tag.includefile.escape_html(true, :doc => 'Special HTML characters in the file content will be escaped if true.')
185
+
186
+ config.tag.executecommand.command(nil, :doc => 'The command which should be executed', :mandatory => 'default')
187
+ config.tag.executecommand.process_output(true, :doc => 'The output of the command will be scanned for tags if true')
188
+ config.tag.executecommand.escape_html(true, :doc => 'Special HTML characters in the output will be escaped if true')
189
+
190
+ config.tag.coderay.lang('ruby', :doc => 'The highlighting language', :mandatory => 'default')
191
+ config.tag.coderay.process_body(true, :doc => 'The tag body will be scanned for tags first if true')
192
+ config.tag.coderay.wrap(:div, :doc => 'Specifies how the code should be wrapped, either :div or :span')
193
+ config.tag.coderay.line_numbers(true, :doc => 'Show line numbers')
194
+ config.tag.coderay.line_number_start(1, :doc => 'Line number of first line')
195
+ config.tag.coderay.bold_every(10, :doc => 'The interval at which the line number appears bold')
196
+ config.tag.coderay.tab_width(8, :doc => 'Number of spaces used for a tabulator')
197
+
198
+ config.tag.date.format('%Y-%m-%d %H:%M:%S', :doc => 'The format of the date (same options as Ruby\'s Time#strftime)')
199
+
200
+ config.tag.tikz.path(nil, :doc => 'The source path of the created image', :mandatory => 'default')
201
+ config.tag.tikz.libraries(nil, :doc => 'An array of additional TikZ library names')
202
+ config.tag.tikz.opts(nil, :doc => 'A string with global options for the tikzpicture environment')
203
+ config.tag.tikz.resolution('72 72', :doc => 'A string specifying the render and output resolutions')
204
+ config.tag.tikz.transparent(false, :doc => 'Specifies whether the generated image should be transparent (only png)')
205
+ config.tag.tikz.img_attr({}, :doc => 'A hash of additional HTML attributes for the created img tag')
206
+
207
+ config.tag.link.path(nil, :doc => 'The (A)LCN path to which a link should be generated', :mandatory => 'default')
208
+ config.tag.link.attr({}, :doc => 'A hash of additional HTML attributes that should be set on the link')
209
+
210
+ # All things regarding common functionality
211
+ website.autoload_service(:create_sitemap, 'Webgen::Common::Sitemap')
212
+
213
+ config.common.sitemap.honor_in_menu(false, :doc => 'Only include pages that are also in the menu if true')
214
+ config.common.sitemap.any_lang(false, :doc => 'Use nodes in any language if true')
215
+ config.common.sitemap.used_kinds(['page'], :doc => 'Array of node kinds that is used for the sitemap')
@@ -0,0 +1,589 @@
1
+ # -*- encoding: utf-8 -*-
2
+
3
+ module Webgen
4
+
5
+ # Describes a human language which is uniquely identfied by a three letter code and, optionally,
6
+ # by an alternative three letter or a two letter code.
7
+ class Language
8
+
9
+ include Comparable
10
+
11
+ # An array containing the language codes for the language.
12
+ attr_reader :codes
13
+
14
+ # The english description of the language.
15
+ attr_reader :description
16
+
17
+ # Create a new language. +codes+ has to be an array containing three strings: the three letter
18
+ # code, the alternative three letter code and the two letter code. If one is not available for
19
+ # the language, it has to be +nil+.
20
+ def initialize(codes, description)
21
+ @codes = codes
22
+ @description = description
23
+ end
24
+
25
+ # The two letter code.
26
+ def code2chars
27
+ @codes[2]
28
+ end
29
+
30
+ # The three letter code.
31
+ def code3chars
32
+ @codes[0]
33
+ end
34
+
35
+ # The alternative three letter code.
36
+ def code3chars_alternative
37
+ @codes[1]
38
+ end
39
+
40
+ # The textual representation of the language.
41
+ def to_s
42
+ code2chars || code3chars
43
+ end
44
+
45
+ alias_method :to_str, :to_s
46
+
47
+ def inspect #:nodoc:
48
+ "#<Language codes=#{codes.inspect} description=#{description.inspect}>"
49
+ end
50
+
51
+ def <=>(other) #:nodoc:
52
+ self.to_s <=> other.to_s
53
+ end
54
+
55
+ def eql?(other) #:nodoc:
56
+ (other.is_a?(self.class) && other.to_s == self.to_s) ||
57
+ (other.is_a?(String) && self.to_s == other)
58
+ end
59
+
60
+ def hash #:nodoc:
61
+ self.to_s.hash
62
+ end
63
+
64
+ end
65
+
66
+
67
+ # Used for managing human languages.
68
+ module LanguageManager
69
+
70
+ # Return a +Language+ object for the given language code or +nil+ if no such object exists.
71
+ def self.language_for_code(code)
72
+ languages[code]
73
+ end
74
+
75
+ # Return an array of +Language+ objects whose description match the given +text+.
76
+ def self.find_language(text)
77
+ languages.values.find_all {|lang| /.*#{Regexp.escape(text)}.*/i =~ lang.description}.uniq.sort
78
+ end
79
+
80
+ # Return all available languages as a Hash. The keys are the language codes and the values are
81
+ # the +Language+ objects for them.
82
+ def self.languages
83
+ unless defined?(@@languages)
84
+ @@languages = {}
85
+ started = nil
86
+ data = File.readlines(__FILE__).each do |l|
87
+ next if !started && (started = (l == '__END__'))
88
+ data = l.chomp.split('|').collect {|f| f.empty? ? nil : f}
89
+ lang = Language.new(data[0..2], data[3])
90
+ @@languages[lang.code2chars] ||= lang unless lang.code2chars.nil?
91
+ @@languages[lang.code3chars] ||= lang unless lang.code3chars.nil?
92
+ @@languages[lang.code3chars_alternative] ||= lang unless lang.code3chars_alternative.nil?
93
+ end
94
+ @@languages.freeze
95
+ end
96
+ @@languages
97
+ end
98
+
99
+ end
100
+
101
+ end
102
+
103
+ __END__
104
+ aar||aa|Afar|afar
105
+ abk||ab|Abkhazian|abkhaze
106
+ ace|||Achinese|aceh
107
+ ach|||Acoli|acoli
108
+ ada|||Adangme|adangme
109
+ ady|||Adyghe; Adygei|adyghé
110
+ afa|||Afro-Asiatic (Other)|afro-asiatiques, autres langues
111
+ afh|||Afrihili|afrihili
112
+ afr||af|Afrikaans|afrikaans
113
+ ain|||Ainu|aïnou
114
+ aka||ak|Akan|akan
115
+ akk|||Akkadian|akkadien
116
+ alb|sqi|sq|Albanian|albanais
117
+ ale|||Aleut|aléoute
118
+ alg|||Algonquian languages|algonquines, langues
119
+ alt|||Southern Altai|altai du Sud
120
+ amh||am|Amharic|amharique
121
+ ang|||English, Old (ca.450-1100)|anglo-saxon (ca.450-1100)
122
+ anp|||Angika|angika
123
+ apa|||Apache languages|apache
124
+ ara||ar|Arabic|arabe
125
+ arc|||Official Aramaic (700-300 BCE); Imperial Aramaic (700-300 BCE)|araméen d'empire (700-300 BCE)
126
+ arg||an|Aragonese|aragonais
127
+ arm|hye|hy|Armenian|arménien
128
+ arn|||Mapudungun; Mapuche|mapudungun; mapuche; mapuce
129
+ arp|||Arapaho|arapaho
130
+ art|||Artificial (Other)|artificielles, autres langues
131
+ arw|||Arawak|arawak
132
+ asm||as|Assamese|assamais
133
+ ast|||Asturian; Bable; Leonese; Asturleonese|asturien; bable; léonais; asturoléonais
134
+ ath|||Athapascan languages|athapascanes, langues
135
+ aus|||Australian languages|australiennes, langues
136
+ ava||av|Avaric|avar
137
+ ave||ae|Avestan|avestique
138
+ awa|||Awadhi|awadhi
139
+ aym||ay|Aymara|aymara
140
+ aze||az|Azerbaijani|azéri
141
+ bad|||Banda languages|banda, langues
142
+ bai|||Bamileke languages|bamilékés, langues
143
+ bak||ba|Bashkir|bachkir
144
+ bal|||Baluchi|baloutchi
145
+ bam||bm|Bambara|bambara
146
+ ban|||Balinese|balinais
147
+ baq|eus|eu|Basque|basque
148
+ bas|||Basa|basa
149
+ bat|||Baltic (Other)|baltiques, autres langues
150
+ bej|||Beja; Bedawiyet|bedja
151
+ bel||be|Belarusian|biélorusse
152
+ bem|||Bemba|bemba
153
+ ben||bn|Bengali|bengali
154
+ ber|||Berber (Other)|berbères, autres langues
155
+ bho|||Bhojpuri|bhojpuri
156
+ bih||bh|Bihari|bihari
157
+ bik|||Bikol|bikol
158
+ bin|||Bini; Edo|bini; edo
159
+ bis||bi|Bislama|bichlamar
160
+ bla|||Siksika|blackfoot
161
+ bnt|||Bantu (Other)|bantoues, autres langues
162
+ bos||bs|Bosnian|bosniaque
163
+ bra|||Braj|braj
164
+ bre||br|Breton|breton
165
+ btk|||Batak languages|batak, langues
166
+ bua|||Buriat|bouriate
167
+ bug|||Buginese|bugi
168
+ bul||bg|Bulgarian|bulgare
169
+ bur|mya|my|Burmese|birman
170
+ byn|||Blin; Bilin|blin; bilen
171
+ cad|||Caddo|caddo
172
+ cai|||Central American Indian (Other)|indiennes d'Amérique centrale, autres langues
173
+ car|||Galibi Carib|karib; galibi; carib
174
+ cat||ca|Catalan; Valencian|catalan; valencien
175
+ cau|||Caucasian (Other)|caucasiennes, autres langues
176
+ ceb|||Cebuano|cebuano
177
+ cel|||Celtic (Other)|celtiques, autres langues
178
+ cha||ch|Chamorro|chamorro
179
+ chb|||Chibcha|chibcha
180
+ che||ce|Chechen|tchétchène
181
+ chg|||Chagatai|djaghataï
182
+ chi|zho|zh|Chinese|chinois
183
+ chk|||Chuukese|chuuk
184
+ chm|||Mari|mari
185
+ chn|||Chinook jargon|chinook, jargon
186
+ cho|||Choctaw|choctaw
187
+ chp|||Chipewyan; Dene Suline|chipewyan
188
+ chr|||Cherokee|cherokee
189
+ chu||cu|Church Slavic; Old Slavonic; Church Slavonic; Old Bulgarian; Old Church Slavonic|slavon d'église; vieux slave; slavon liturgique; vieux bulgare
190
+ chv||cv|Chuvash|tchouvache
191
+ chy|||Cheyenne|cheyenne
192
+ cmc|||Chamic languages|chames, langues
193
+ cop|||Coptic|copte
194
+ cor||kw|Cornish|cornique
195
+ cos||co|Corsican|corse
196
+ cpe|||Creoles and pidgins, English based (Other)|créoles et pidgins anglais, autres
197
+ cpf|||Creoles and pidgins, French-based (Other)|créoles et pidgins français, autres
198
+ cpp|||Creoles and pidgins, Portuguese-based (Other)|créoles et pidgins portugais, autres
199
+ cre||cr|Cree|cree
200
+ crh|||Crimean Tatar; Crimean Turkish|tatar de Crimé
201
+ crp|||Creoles and pidgins (Other)|créoles et pidgins divers
202
+ csb|||Kashubian|kachoube
203
+ cus|||Cushitic (Other)|couchitiques, autres langues
204
+ cze|ces|cs|Czech|tchèque
205
+ dak|||Dakota|dakota
206
+ dan||da|Danish|danois
207
+ dar|||Dargwa|dargwa
208
+ day|||Land Dayak languages|dayak, langues
209
+ del|||Delaware|delaware
210
+ den|||Slave (Athapascan)|esclave (athapascan)
211
+ dgr|||Dogrib|dogrib
212
+ din|||Dinka|dinka
213
+ div||dv|Divehi; Dhivehi; Maldivian|maldivien
214
+ doi|||Dogri|dogri
215
+ dra|||Dravidian (Other)|dravidiennes, autres langues
216
+ dsb|||Lower Sorbian|bas-sorabe
217
+ dua|||Duala|douala
218
+ dum|||Dutch, Middle (ca.1050-1350)|néerlandais moyen (ca. 1050-1350)
219
+ dut|nld|nl|Dutch; Flemish|néerlandais; flamand
220
+ dyu|||Dyula|dioula
221
+ dzo||dz|Dzongkha|dzongkha
222
+ efi|||Efik|efik
223
+ egy|||Egyptian (Ancient)|égyptien
224
+ eka|||Ekajuk|ekajuk
225
+ elx|||Elamite|élamite
226
+ eng||en|English|anglais
227
+ enm|||English, Middle (1100-1500)|anglais moyen (1100-1500)
228
+ epo||eo|Esperanto|espéranto
229
+ est||et|Estonian|estonien
230
+ ewe||ee|Ewe|éwé
231
+ ewo|||Ewondo|éwondo
232
+ fan|||Fang|fang
233
+ fao||fo|Faroese|féroïen
234
+ fat|||Fanti|fanti
235
+ fij||fj|Fijian|fidjien
236
+ fil|||Filipino; Pilipino|filipino; pilipino
237
+ fin||fi|Finnish|finnois
238
+ fiu|||Finno-Ugrian (Other)|finno-ougriennes, autres langues
239
+ fon|||Fon|fon
240
+ fre|fra|fr|French|français
241
+ frm|||French, Middle (ca.1400-1600)|français moyen (1400-1600)
242
+ fro|||French, Old (842-ca.1400)|français ancien (842-ca.1400)
243
+ frr|||Northern Frisian|frison septentrional
244
+ frs|||Eastern Frisian|frison oriental
245
+ fry||fy|Western Frisian|frison occidental
246
+ ful||ff|Fulah|peul
247
+ fur|||Friulian|frioulan
248
+ gaa|||Ga|ga
249
+ gay|||Gayo|gayo
250
+ gba|||Gbaya|gbaya
251
+ gem|||Germanic (Other)|germaniques, autres langues
252
+ geo|kat|ka|Georgian|géorgien
253
+ ger|deu|de|German|allemand
254
+ gez|||Geez|guèze
255
+ gil|||Gilbertese|kiribati
256
+ gla||gd|Gaelic; Scottish Gaelic|gaélique; gaélique écossais
257
+ gle||ga|Irish|irlandais
258
+ glg||gl|Galician|galicien
259
+ glv||gv|Manx|manx; mannois
260
+ gmh|||German, Middle High (ca.1050-1500)|allemand, moyen haut (ca. 1050-1500)
261
+ goh|||German, Old High (ca.750-1050)|allemand, vieux haut (ca. 750-1050)
262
+ gon|||Gondi|gond
263
+ gor|||Gorontalo|gorontalo
264
+ got|||Gothic|gothique
265
+ grb|||Grebo|grebo
266
+ grc|||Greek, Ancient (to 1453)|grec ancien (jusqu'à 1453)
267
+ gre|ell|el|Greek, Modern (1453-)|grec moderne (après 1453)
268
+ grn||gn|Guarani|guarani
269
+ gsw|||Swiss German; Alemannic; Alsatian|suisse alémanique; alémanique; alsacien
270
+ guj||gu|Gujarati|goudjrati
271
+ gwi|||Gwich'in|gwich'in
272
+ hai|||Haida|haida
273
+ hat||ht|Haitian; Haitian Creole|haïtien; créole haïtien
274
+ hau||ha|Hausa|haoussa
275
+ haw|||Hawaiian|hawaïen
276
+ heb||he|Hebrew|hébreu
277
+ her||hz|Herero|herero
278
+ hil|||Hiligaynon|hiligaynon
279
+ him|||Himachali|himachali
280
+ hin||hi|Hindi|hindi
281
+ hit|||Hittite|hittite
282
+ hmn|||Hmong|hmong
283
+ hmo||ho|Hiri Motu|hiri motu
284
+ hsb|||Upper Sorbian|haut-sorabe
285
+ hun||hu|Hungarian|hongrois
286
+ hup|||Hupa|hupa
287
+ iba|||Iban|iban
288
+ ibo||ig|Igbo|igbo
289
+ ice|isl|is|Icelandic|islandais
290
+ ido||io|Ido|ido
291
+ iii||ii|Sichuan Yi; Nuosu|yi de Sichuan
292
+ ijo|||Ijo languages|ijo, langues
293
+ iku||iu|Inuktitut|inuktitut
294
+ ile||ie|Interlingue; Occidental|interlingue
295
+ ilo|||Iloko|ilocano
296
+ ina||ia|Interlingua (International Auxiliary Language Association)|interlingua (langue auxiliaire internationale)
297
+ inc|||Indic (Other)|indo-aryennes, autres langues
298
+ ind||id|Indonesian|indonésien
299
+ ine|||Indo-European (Other)|indo-européennes, autres langues
300
+ inh|||Ingush|ingouche
301
+ ipk||ik|Inupiaq|inupiaq
302
+ ira|||Iranian (Other)|iraniennes, autres langues
303
+ iro|||Iroquoian languages|iroquoises, langues (famille)
304
+ ita||it|Italian|italien
305
+ jav||jv|Javanese|javanais
306
+ jbo|||Lojban|lojban
307
+ jpn||ja|Japanese|japonais
308
+ jpr|||Judeo-Persian|judéo-persan
309
+ jrb|||Judeo-Arabic|judéo-arabe
310
+ kaa|||Kara-Kalpak|karakalpak
311
+ kab|||Kabyle|kabyle
312
+ kac|||Kachin; Jingpho|kachin; jingpho
313
+ kal||kl|Kalaallisut; Greenlandic|groenlandais
314
+ kam|||Kamba|kamba
315
+ kan||kn|Kannada|kannada
316
+ kar|||Karen languages|karen, langues
317
+ kas||ks|Kashmiri|kashmiri
318
+ kau||kr|Kanuri|kanouri
319
+ kaw|||Kawi|kawi
320
+ kaz||kk|Kazakh|kazakh
321
+ kbd|||Kabardian|kabardien
322
+ kha|||Khasi|khasi
323
+ khi|||Khoisan (Other)|khoisan, autres langues
324
+ khm||km|Central Khmer|khmer central
325
+ kho|||Khotanese|khotanais
326
+ kik||ki|Kikuyu; Gikuyu|kikuyu
327
+ kin||rw|Kinyarwanda|rwanda
328
+ kir||ky|Kirghiz; Kyrgyz|kirghiz
329
+ kmb|||Kimbundu|kimbundu
330
+ kok|||Konkani|konkani
331
+ kom||kv|Komi|kom
332
+ kon||kg|Kongo|kongo
333
+ kor||ko|Korean|coréen
334
+ kos|||Kosraean|kosrae
335
+ kpe|||Kpelle|kpellé
336
+ krc|||Karachay-Balkar|karatchai balkar
337
+ krl|||Karelian|carélien
338
+ kro|||Kru languages|krou, langues
339
+ kru|||Kurukh|kurukh
340
+ kua||kj|Kuanyama; Kwanyama|kuanyama; kwanyama
341
+ kum|||Kumyk|koumyk
342
+ kur||ku|Kurdish|kurde
343
+ kut|||Kutenai|kutenai
344
+ lad|||Ladino|judéo-espagnol
345
+ lah|||Lahnda|lahnda
346
+ lam|||Lamba|lamba
347
+ lao||lo|Lao|lao
348
+ lat||la|Latin|latin
349
+ lav||lv|Latvian|letton
350
+ lez|||Lezghian|lezghien
351
+ lim||li|Limburgan; Limburger; Limburgish|limbourgeois
352
+ lin||ln|Lingala|lingala
353
+ lit||lt|Lithuanian|lituanien
354
+ lol|||Mongo|mongo
355
+ loz|||Lozi|lozi
356
+ ltz||lb|Luxembourgish; Letzeburgesch|luxembourgeois
357
+ lua|||Luba-Lulua|luba-lulua
358
+ lub||lu|Luba-Katanga|luba-katanga
359
+ lug||lg|Ganda|ganda
360
+ lui|||Luiseno|luiseno
361
+ lun|||Lunda|lunda
362
+ luo|||Luo (Kenya and Tanzania)|luo (Kenya et Tanzanie)
363
+ lus|||Lushai|lushai
364
+ mac|mkd|mk|Macedonian|macédonien
365
+ mad|||Madurese|madourais
366
+ mag|||Magahi|magahi
367
+ mah||mh|Marshallese|marshall
368
+ mai|||Maithili|maithili
369
+ mak|||Makasar|makassar
370
+ mal||ml|Malayalam|malayalam
371
+ man|||Mandingo|mandingue
372
+ mao|mri|mi|Maori|maori
373
+ map|||Austronesian (Other)|malayo-polynésiennes, autres langues
374
+ mar||mr|Marathi|marathe
375
+ mas|||Masai|massaï
376
+ may|msa|ms|Malay|malais
377
+ mdf|||Moksha|moksa
378
+ mdr|||Mandar|mandar
379
+ men|||Mende|mendé
380
+ mga|||Irish, Middle (900-1200)|irlandais moyen (900-1200)
381
+ mic|||Mi'kmaq; Micmac|mi'kmaq; micmac
382
+ min|||Minangkabau|minangkabau
383
+ mis|||Uncoded languages|langues non codées
384
+ mkh|||Mon-Khmer (Other)|môn-khmer, autres langues
385
+ mlg||mg|Malagasy|malgache
386
+ mlt||mt|Maltese|maltais
387
+ mnc|||Manchu|mandchou
388
+ mni|||Manipuri|manipuri
389
+ mno|||Manobo languages|manobo, langues
390
+ moh|||Mohawk|mohawk
391
+ mol||mo|Moldavian|moldave
392
+ mon||mn|Mongolian|mongol
393
+ mos|||Mossi|moré
394
+ mul|||Multiple languages|multilingue
395
+ mun|||Munda languages|mounda, langues
396
+ mus|||Creek|muskogee
397
+ mwl|||Mirandese|mirandais
398
+ mwr|||Marwari|marvari
399
+ myn|||Mayan languages|maya, langues
400
+ myv|||Erzya|erza
401
+ nah|||Nahuatl languages|nahuatl, langues
402
+ nai|||North American Indian|indiennes d'Amérique du Nord, autres langues
403
+ nap|||Neapolitan|napolitain
404
+ nau||na|Nauru|nauruan
405
+ nav||nv|Navajo; Navaho|navaho
406
+ nbl||nr|Ndebele, South; South Ndebele|ndébélé du Sud
407
+ nde||nd|Ndebele, North; North Ndebele|ndébélé du Nord
408
+ ndo||ng|Ndonga|ndonga
409
+ nds|||Low German; Low Saxon; German, Low; Saxon, Low|bas allemand; bas saxon; allemand, bas; saxon, bas
410
+ nep||ne|Nepali|népalais
411
+ new|||Nepal Bhasa; Newari|nepal bhasa; newari
412
+ nia|||Nias|nias
413
+ nic|||Niger-Kordofanian (Other)|nigéro-congolaises, autres langues
414
+ niu|||Niuean|niué
415
+ nno||nn|Norwegian Nynorsk; Nynorsk, Norwegian|norvégien nynorsk; nynorsk, norvégien
416
+ nob||nb|Bokmål, Norwegian; Norwegian Bokmål|norvégien bokmål
417
+ nog|||Nogai|nogaï; nogay
418
+ non|||Norse, Old|norrois, vieux
419
+ nor||no|Norwegian|norvégien
420
+ nqo|||N'Ko|n'ko
421
+ nso|||Pedi; Sepedi; Northern Sotho|pedi; sepedi; sotho du Nord
422
+ nub|||Nubian languages|nubiennes, langues
423
+ nwc|||Classical Newari; Old Newari; Classical Nepal Bhasa|newari classique
424
+ nya||ny|Chichewa; Chewa; Nyanja|chichewa; chewa; nyanja
425
+ nym|||Nyamwezi|nyamwezi
426
+ nyn|||Nyankole|nyankolé
427
+ nyo|||Nyoro|nyoro
428
+ nzi|||Nzima|nzema
429
+ oci||oc|Occitan (post 1500); Provençal|occitan (après 1500); provençal
430
+ oji||oj|Ojibwa|ojibwa
431
+ ori||or|Oriya|oriya
432
+ orm||om|Oromo|galla
433
+ osa|||Osage|osage
434
+ oss||os|Ossetian; Ossetic|ossète
435
+ ota|||Turkish, Ottoman (1500-1928)|turc ottoman (1500-1928)
436
+ oto|||Otomian languages|otomangue, langues
437
+ paa|||Papuan (Other)|papoues, autres langues
438
+ pag|||Pangasinan|pangasinan
439
+ pal|||Pahlavi|pahlavi
440
+ pam|||Pampanga; Kapampangan|pampangan
441
+ pan||pa|Panjabi; Punjabi|pendjabi
442
+ pap|||Papiamento|papiamento
443
+ pau|||Palauan|palau
444
+ peo|||Persian, Old (ca.600-400 B.C.)|perse, vieux (ca. 600-400 av. J.-C.)
445
+ per|fas|fa|Persian|persan
446
+ phi|||Philippine (Other)|philippines, autres langues
447
+ phn|||Phoenician|phénicien
448
+ pli||pi|Pali|pali
449
+ pol||pl|Polish|polonais
450
+ pon|||Pohnpeian|pohnpei
451
+ por||pt|Portuguese|portugais
452
+ pra|||Prakrit languages|prâkrit
453
+ pro|||Provençal, Old (to 1500)|provençal ancien (jusqu'à 1500)
454
+ pus||ps|Pushto; Pashto|pachto
455
+ qaa-qtz|||Reserved for local use|réservée à l'usage local
456
+ que||qu|Quechua|quechua
457
+ raj|||Rajasthani|rajasthani
458
+ rap|||Rapanui|rapanui
459
+ rar|||Rarotongan; Cook Islands Maori|rarotonga; maori des îles Cook
460
+ roa|||Romance (Other)|romanes, autres langues
461
+ roh||rm|Romansh|romanche
462
+ rom|||Romany|tsigane
463
+ rum|ron|ro|Romanian|roumain
464
+ run||rn|Rundi|rundi
465
+ rup|||Aromanian; Arumanian; Macedo-Romanian|aroumain; macédo-roumain
466
+ rus||ru|Russian|russe
467
+ sad|||Sandawe|sandawe
468
+ sag||sg|Sango|sango
469
+ sah|||Yakut|iakoute
470
+ sai|||South American Indian (Other)|indiennes d'Amérique du Sud, autres langues
471
+ sal|||Salishan languages|salish, langues
472
+ sam|||Samaritan Aramaic|samaritain
473
+ san||sa|Sanskrit|sanskrit
474
+ sas|||Sasak|sasak
475
+ sat|||Santali|santal
476
+ scc|srp|sr|Serbian|serbe
477
+ scn|||Sicilian|sicilien
478
+ sco|||Scots|écossais
479
+ scr|hrv|hr|Croatian|croate
480
+ sel|||Selkup|selkoupe
481
+ sem|||Semitic (Other)|sémitiques, autres langues
482
+ sga|||Irish, Old (to 900)|irlandais ancien (jusqu'à 900)
483
+ sgn|||Sign Languages|langues des signes
484
+ shn|||Shan|chan
485
+ sid|||Sidamo|sidamo
486
+ sin||si|Sinhala; Sinhalese|singhalais
487
+ sio|||Siouan languages|sioux, langues
488
+ sit|||Sino-Tibetan (Other)|sino-tibétaines, autres langues
489
+ sla|||Slavic (Other)|slaves, autres langues
490
+ slo|slk|sk|Slovak|slovaque
491
+ slv||sl|Slovenian|slovène
492
+ sma|||Southern Sami|sami du Sud
493
+ sme||se|Northern Sami|sami du Nord
494
+ smi|||Sami languages (Other)|sami, autres langues
495
+ smj|||Lule Sami|sami de Lule
496
+ smn|||Inari Sami|sami d'Inari
497
+ smo||sm|Samoan|samoan
498
+ sms|||Skolt Sami|sami skolt
499
+ sna||sn|Shona|shona
500
+ snd||sd|Sindhi|sindhi
501
+ snk|||Soninke|soninké
502
+ sog|||Sogdian|sogdien
503
+ som||so|Somali|somali
504
+ son|||Songhai languages|songhai, langues
505
+ sot||st|Sotho, Southern|sotho du Sud
506
+ spa||es|Spanish; Castilian|espagnol; castillan
507
+ srd||sc|Sardinian|sarde
508
+ srn|||Sranan Tongo|sranan tongo
509
+ srr|||Serer|sérère
510
+ ssa|||Nilo-Saharan (Other)|nilo-sahariennes, autres langues
511
+ ssw||ss|Swati|swati
512
+ suk|||Sukuma|sukuma
513
+ sun||su|Sundanese|soundanais
514
+ sus|||Susu|soussou
515
+ sux|||Sumerian|sumérien
516
+ swa||sw|Swahili|swahili
517
+ swe||sv|Swedish|suédois
518
+ syc|||Classical Syriac|syriaque classique
519
+ syr|||Syriac|syriaque
520
+ tah||ty|Tahitian|tahitien
521
+ tai|||Tai (Other)|thaïes, autres langues
522
+ tam||ta|Tamil|tamoul
523
+ tat||tt|Tatar|tatar
524
+ tel||te|Telugu|télougou
525
+ tem|||Timne|temne
526
+ ter|||Tereno|tereno
527
+ tet|||Tetum|tetum
528
+ tgk||tg|Tajik|tadjik
529
+ tgl||tl|Tagalog|tagalog
530
+ tha||th|Thai|thaï
531
+ tib|bod|bo|Tibetan|tibétain
532
+ tig|||Tigre|tigré
533
+ tir||ti|Tigrinya|tigrigna
534
+ tiv|||Tiv|tiv
535
+ tkl|||Tokelau|tokelau
536
+ tlh|||Klingon; tlhIngan-Hol|klingon
537
+ tli|||Tlingit|tlingit
538
+ tmh|||Tamashek|tamacheq
539
+ tog|||Tonga (Nyasa)|tonga (Nyasa)
540
+ ton||to|Tonga (Tonga Islands)|tongan (Îles Tonga)
541
+ tpi|||Tok Pisin|tok pisin
542
+ tsi|||Tsimshian|tsimshian
543
+ tsn||tn|Tswana|tswana
544
+ tso||ts|Tsonga|tsonga
545
+ tuk||tk|Turkmen|turkmène
546
+ tum|||Tumbuka|tumbuka
547
+ tup|||Tupi languages|tupi, langues
548
+ tur||tr|Turkish|turc
549
+ tut|||Altaic (Other)|altaïques, autres langues
550
+ tvl|||Tuvalu|tuvalu
551
+ twi||tw|Twi|twi
552
+ tyv|||Tuvinian|touva
553
+ udm|||Udmurt|oudmourte
554
+ uga|||Ugaritic|ougaritique
555
+ uig||ug|Uighur; Uyghur|ouïgour
556
+ ukr||uk|Ukrainian|ukrainien
557
+ umb|||Umbundu|umbundu
558
+ und|||Undetermined|indéterminée
559
+ urd||ur|Urdu|ourdou
560
+ uzb||uz|Uzbek|ouszbek
561
+ vai|||Vai|vaï
562
+ ven||ve|Venda|venda
563
+ vie||vi|Vietnamese|vietnamien
564
+ vol||vo|Volapük|volapük
565
+ vot|||Votic|vote
566
+ wak|||Wakashan languages|wakashennes, langues
567
+ wal|||Walamo|walamo
568
+ war|||Waray|waray
569
+ was|||Washo|washo
570
+ wel|cym|cy|Welsh|gallois
571
+ wen|||Sorbian languages|sorabes, langues
572
+ wln||wa|Walloon|wallon
573
+ wol||wo|Wolof|wolof
574
+ xal|||Kalmyk; Oirat|kalmouk; oïrat
575
+ xho||xh|Xhosa|xhosa
576
+ yao|||Yao|yao
577
+ yap|||Yapese|yapois
578
+ yid||yi|Yiddish|yiddish
579
+ yor||yo|Yoruba|yoruba
580
+ ypk|||Yupik languages|yupik, langues
581
+ zap|||Zapotec|zapotèque
582
+ zbl|||Blissymbols; Blissymbolics; Bliss|symboles Bliss; Bliss
583
+ zen|||Zenaga|zenaga
584
+ zha||za|Zhuang; Chuang|zhuang; chuang
585
+ znd|||Zande languages|zandé, langues
586
+ zul||zu|Zulu|zoulou
587
+ zun|||Zuni|zuni
588
+ zxx|||No linguistic content|pas de contenu linguistique
589
+ zza|||Zaza; Dimili; Dimli; Kirdki; Kirmanjki; Zazaki|zaza; dimili; dimli; kirdki; kirmanjki; zazaki