wlang 0.10.2 → 2.0.0.beta

Sign up to get free protection for your applications and to get access to all the features.
Files changed (269) hide show
  1. data/CHANGELOG.md +3 -121
  2. data/Gemfile +23 -1
  3. data/Gemfile.lock +32 -28
  4. data/LICENCE.md +18 -21
  5. data/Manifest.txt +4 -5
  6. data/README.md +100 -174
  7. data/Rakefile +1 -13
  8. data/bin/wlang +3 -29
  9. data/lib/wlang.rb +21 -394
  10. data/lib/wlang/command.rb +94 -0
  11. data/lib/wlang/compiler.rb +78 -0
  12. data/lib/wlang/compiler/autospacing.rb +60 -0
  13. data/lib/wlang/compiler/dialect_enforcer.rb +91 -0
  14. data/lib/wlang/compiler/filter.rb +32 -0
  15. data/lib/wlang/compiler/grammar.citrus +67 -0
  16. data/lib/wlang/compiler/parser.rb +26 -0
  17. data/lib/wlang/compiler/proc_call_removal.rb +15 -0
  18. data/lib/wlang/compiler/static_merger.rb +28 -0
  19. data/lib/wlang/compiler/strconcat_flattener.rb +25 -0
  20. data/lib/wlang/compiler/to_ruby_abstraction.rb +22 -0
  21. data/lib/wlang/compiler/to_ruby_code.rb +55 -0
  22. data/lib/wlang/dialect.rb +40 -237
  23. data/lib/wlang/dialect/dispatching.rb +51 -0
  24. data/lib/wlang/dialect/evaluation.rb +30 -0
  25. data/lib/wlang/dialect/tags.rb +50 -0
  26. data/lib/wlang/dummy.rb +32 -0
  27. data/lib/wlang/html.rb +106 -0
  28. data/lib/wlang/loader.rb +6 -0
  29. data/lib/wlang/mustang.rb +90 -0
  30. data/lib/wlang/scope.rb +57 -0
  31. data/lib/wlang/scope/binding_scope.rb +18 -0
  32. data/lib/wlang/scope/object_scope.rb +25 -0
  33. data/lib/wlang/scope/proxy_scope.rb +18 -0
  34. data/lib/wlang/scope/root_scope.rb +24 -0
  35. data/lib/wlang/template.rb +16 -86
  36. data/lib/wlang/version.rb +9 -8
  37. data/spec/fixtures/dialect/foobar.rb +31 -0
  38. data/spec/fixtures/dialect/upcasing.rb +13 -0
  39. data/spec/fixtures/templates/hello.tpl +1 -0
  40. data/spec/integration/examples/1-basics.txt +65 -0
  41. data/spec/integration/examples/2-imperative.txt +51 -0
  42. data/spec/integration/examples/3-partials.txt +76 -0
  43. data/spec/integration/examples/4-recursion.txt +16 -0
  44. data/spec/integration/html/test_ampersand.rb +15 -0
  45. data/spec/integration/html/test_bang.rb +38 -0
  46. data/spec/integration/html/test_caret.rb +33 -0
  47. data/spec/integration/html/test_dollar.rb +16 -0
  48. data/spec/integration/html/test_greater.rb +23 -0
  49. data/spec/integration/html/test_modulo.rb +16 -0
  50. data/spec/integration/html/test_plus.rb +48 -0
  51. data/spec/integration/html/test_question.rb +33 -0
  52. data/spec/integration/html/test_sharp.rb +21 -0
  53. data/spec/integration/html/test_slash.rb +16 -0
  54. data/spec/integration/html/test_star.rb +37 -0
  55. data/spec/integration/test_dummy.rb +51 -0
  56. data/spec/integration/test_examples.rb +29 -0
  57. data/spec/integration/test_mustang.rb +120 -0
  58. data/spec/integration/test_readme.rb +56 -0
  59. data/spec/integration/test_upcasing.rb +22 -0
  60. data/spec/spec_helper.rb +62 -1
  61. data/spec/test_wlang.rb +101 -0
  62. data/spec/unit/compiler/autospacing/test_right_strip.rb +30 -0
  63. data/spec/unit/compiler/autospacing/test_unindent.rb +30 -0
  64. data/spec/unit/compiler/test_dialect_enforcer.rb +168 -0
  65. data/spec/unit/compiler/test_grammar.rb +207 -0
  66. data/spec/unit/compiler/test_parser.rb +69 -0
  67. data/spec/unit/compiler/test_proc_call_removal.rb +24 -0
  68. data/spec/unit/compiler/test_static_merger.rb +29 -0
  69. data/spec/unit/compiler/test_strconcat_flattener.rb +30 -0
  70. data/spec/unit/compiler/test_to_ruby_abstraction.rb +59 -0
  71. data/spec/unit/compiler/test_to_ruby_code.rb +24 -0
  72. data/spec/unit/dialect/test_compile.rb +52 -0
  73. data/spec/unit/dialect/test_dispatching.rb +19 -0
  74. data/spec/unit/dialect/test_evaluate.rb +41 -0
  75. data/spec/unit/dialect/test_render.rb +33 -0
  76. data/spec/unit/dialect/test_tags.rb +32 -0
  77. data/spec/unit/dialect/test_with_scope.rb +18 -0
  78. data/spec/unit/scope/test_binding_scope.rb +27 -0
  79. data/spec/unit/scope/test_coerce.rb +22 -0
  80. data/spec/unit/scope/test_object_scope.rb +38 -0
  81. data/spec/unit/scope/test_proxy_scope.rb +22 -0
  82. data/spec/unit/scope/test_root_scope.rb +22 -0
  83. data/spec/unit/test_assumptions.rb +29 -0
  84. data/spec/unit/test_scope.rb +57 -0
  85. data/tasks/debug_mail.rake +42 -45
  86. data/tasks/gem.rake +22 -17
  87. data/tasks/spec_test.rake +9 -17
  88. data/tasks/unit_test.rake +11 -12
  89. data/tasks/yard.rake +13 -13
  90. data/wlang.gemspec +36 -32
  91. data/wlang.noespec +27 -35
  92. metadata +268 -451
  93. data/doc/specification/about.rdoc +0 -61
  94. data/doc/specification/analytics.wtpl +0 -13
  95. data/doc/specification/dialect.wtpl +0 -14
  96. data/doc/specification/dialects.wtpl +0 -3
  97. data/doc/specification/examples.rb +0 -3
  98. data/doc/specification/glossary.wtpl +0 -14
  99. data/doc/specification/hosting.rdoc +0 -0
  100. data/doc/specification/overview.rdoc +0 -116
  101. data/doc/specification/rulesets.wtpl +0 -87
  102. data/doc/specification/specification.css +0 -53
  103. data/doc/specification/specification.html +0 -1690
  104. data/doc/specification/specification.js +0 -8
  105. data/doc/specification/specification.wtpl +0 -42
  106. data/doc/specification/specification.yml +0 -432
  107. data/doc/specification/symbols.wtpl +0 -16
  108. data/lib/wlang/dialect_dsl.rb +0 -141
  109. data/lib/wlang/dialect_loader.rb +0 -74
  110. data/lib/wlang/dialects/bluecloth_dialect.rb +0 -16
  111. data/lib/wlang/dialects/coderay_dialect.rb +0 -45
  112. data/lib/wlang/dialects/hosted_dialect.rb +0 -50
  113. data/lib/wlang/dialects/plain_text_dialect.rb +0 -69
  114. data/lib/wlang/dialects/rdoc_dialect.rb +0 -33
  115. data/lib/wlang/dialects/redcloth_dialect.rb +0 -16
  116. data/lib/wlang/dialects/ruby_dialect.rb +0 -118
  117. data/lib/wlang/dialects/sql_dialect.rb +0 -38
  118. data/lib/wlang/dialects/standard_dialects.rb +0 -181
  119. data/lib/wlang/dialects/xhtml_dialect.rb +0 -63
  120. data/lib/wlang/dialects/yaml_dialect.rb +0 -30
  121. data/lib/wlang/encoder.rb +0 -62
  122. data/lib/wlang/encoder_set.rb +0 -122
  123. data/lib/wlang/errors.rb +0 -80
  124. data/lib/wlang/ext/hash_methodize.rb +0 -13
  125. data/lib/wlang/ext/string.rb +0 -44
  126. data/lib/wlang/hash_scope.rb +0 -89
  127. data/lib/wlang/hosted_language.rb +0 -146
  128. data/lib/wlang/intelligent_buffer.rb +0 -94
  129. data/lib/wlang/parser.rb +0 -332
  130. data/lib/wlang/parser_state.rb +0 -94
  131. data/lib/wlang/rule.rb +0 -66
  132. data/lib/wlang/rule_set.rb +0 -106
  133. data/lib/wlang/rulesets/basic_ruleset.rb +0 -83
  134. data/lib/wlang/rulesets/buffering_ruleset.rb +0 -115
  135. data/lib/wlang/rulesets/context_ruleset.rb +0 -111
  136. data/lib/wlang/rulesets/encoding_ruleset.rb +0 -73
  137. data/lib/wlang/rulesets/imperative_ruleset.rb +0 -132
  138. data/lib/wlang/rulesets/ruleset_utils.rb +0 -317
  139. data/lib/wlang/wlang_command.rb +0 -51
  140. data/lib/wlang/wlang_command_options.rb +0 -163
  141. data/spec/basic_object.spec +0 -40
  142. data/spec/coderay_dialect.spec +0 -8
  143. data/spec/dialect/apply_post_transform.spec +0 -16
  144. data/spec/global_extensions.rb +0 -2
  145. data/spec/hash_scope.spec +0 -76
  146. data/spec/redcloth_dialect.spec +0 -24
  147. data/spec/test_all.rb +0 -8
  148. data/spec/wlang.spec +0 -53
  149. data/spec/wlang_spec.rb +0 -8
  150. data/spec/xhtml_dialect.spec +0 -22
  151. data/tasks/genspec.rake +0 -5
  152. data/test/blackbox/basic/execution_1.exp +0 -1
  153. data/test/blackbox/basic/execution_1.tpl +0 -1
  154. data/test/blackbox/basic/execution_2.exp +0 -1
  155. data/test/blackbox/basic/execution_2.tpl +0 -1
  156. data/test/blackbox/basic/execution_3.exp +0 -1
  157. data/test/blackbox/basic/execution_3.tpl +0 -1
  158. data/test/blackbox/basic/execution_4.exp +0 -1
  159. data/test/blackbox/basic/execution_4.tpl +0 -1
  160. data/test/blackbox/basic/inclusion_1.exp +0 -1
  161. data/test/blackbox/basic/inclusion_1.tpl +0 -1
  162. data/test/blackbox/basic/inclusion_2.exp +0 -1
  163. data/test/blackbox/basic/inclusion_2.tpl +0 -1
  164. data/test/blackbox/basic/injection_1.exp +0 -1
  165. data/test/blackbox/basic/injection_1.tpl +0 -1
  166. data/test/blackbox/basic/injection_2.exp +0 -1
  167. data/test/blackbox/basic/injection_2.tpl +0 -1
  168. data/test/blackbox/basic/modulation_1.exp +0 -1
  169. data/test/blackbox/basic/modulation_1.tpl +0 -1
  170. data/test/blackbox/basic/modulation_2.exp +0 -1
  171. data/test/blackbox/basic/modulation_2.tpl +0 -1
  172. data/test/blackbox/basic/recursive_app_1.exp +0 -1
  173. data/test/blackbox/basic/recursive_app_1.tpl +0 -1
  174. data/test/blackbox/basic/recursive_app_2.exp +0 -1
  175. data/test/blackbox/basic/recursive_app_2.tpl +0 -1
  176. data/test/blackbox/buffering/data_1.rb +0 -1
  177. data/test/blackbox/buffering/data_assignment_1.exp +0 -1
  178. data/test/blackbox/buffering/data_assignment_1.tpl +0 -1
  179. data/test/blackbox/buffering/data_assignment_2.exp +0 -1
  180. data/test/blackbox/buffering/data_assignment_2.tpl +0 -1
  181. data/test/blackbox/buffering/data_assignment_3.exp +0 -1
  182. data/test/blackbox/buffering/data_assignment_3.tpl +0 -1
  183. data/test/blackbox/buffering/data_assignment_4.exp +0 -1
  184. data/test/blackbox/buffering/data_assignment_4.tpl +0 -1
  185. data/test/blackbox/buffering/input_1.exp +0 -1
  186. data/test/blackbox/buffering/input_1.tpl +0 -1
  187. data/test/blackbox/buffering/input_2.exp +0 -1
  188. data/test/blackbox/buffering/input_2.tpl +0 -1
  189. data/test/blackbox/buffering/input_3.exp +0 -1
  190. data/test/blackbox/buffering/input_3.tpl +0 -1
  191. data/test/blackbox/buffering/input_inclusion.exp +0 -1
  192. data/test/blackbox/buffering/input_inclusion.tpl +0 -1
  193. data/test/blackbox/buffering/input_inclusion_1.exp +0 -0
  194. data/test/blackbox/buffering/input_inclusion_1.tpl +0 -1
  195. data/test/blackbox/buffering/input_inclusion_2.exp +0 -1
  196. data/test/blackbox/buffering/input_inclusion_2.tpl +0 -1
  197. data/test/blackbox/buffering/input_inclusion_3.exp +0 -1
  198. data/test/blackbox/buffering/input_inclusion_3.tpl +0 -1
  199. data/test/blackbox/buffering/input_inclusion_4.exp +0 -0
  200. data/test/blackbox/buffering/input_inclusion_4.tpl +0 -1
  201. data/test/blackbox/buffering/input_inclusion_5.exp +0 -1
  202. data/test/blackbox/buffering/input_inclusion_5.tpl +0 -1
  203. data/test/blackbox/buffering/input_inclusion_6.exp +0 -1
  204. data/test/blackbox/buffering/input_inclusion_6.tpl +0 -1
  205. data/test/blackbox/buffering/input_inclusion_7.exp +0 -0
  206. data/test/blackbox/buffering/input_inclusion_7.tpl +0 -1
  207. data/test/blackbox/buffering/text_1.txt +0 -1
  208. data/test/blackbox/buffering/wlang.txt +0 -1
  209. data/test/blackbox/context/assignment_1.exp +0 -1
  210. data/test/blackbox/context/assignment_1.tpl +0 -1
  211. data/test/blackbox/context/assignment_2.exp +0 -1
  212. data/test/blackbox/context/assignment_2.tpl +0 -1
  213. data/test/blackbox/context/assignment_3.exp +0 -2
  214. data/test/blackbox/context/assignment_3.tpl +0 -2
  215. data/test/blackbox/context/assignment_4.exp +0 -1
  216. data/test/blackbox/context/assignment_4.tpl +0 -1
  217. data/test/blackbox/context/block_assignment_1.exp +0 -1
  218. data/test/blackbox/context/block_assignment_1.tpl +0 -1
  219. data/test/blackbox/context/block_assignment_2.exp +0 -1
  220. data/test/blackbox/context/block_assignment_2.tpl +0 -1
  221. data/test/blackbox/context/modulo_assignment_1.exp +0 -1
  222. data/test/blackbox/context/modulo_assignment_1.tpl +0 -1
  223. data/test/blackbox/context/modulo_assignment_2.exp +0 -1
  224. data/test/blackbox/context/modulo_assignment_2.tpl +0 -1
  225. data/test/blackbox/data_1.rb +0 -1
  226. data/test/blackbox/postblock/hello.exp +0 -1
  227. data/test/blackbox/postblock/hello.pre +0 -1
  228. data/test/blackbox/postblock/hello.tpl +0 -1
  229. data/test/blackbox/postblock/hello_input_inclusion.exp +0 -1
  230. data/test/blackbox/postblock/hello_input_inclusion.tpl +0 -1
  231. data/test/blackbox/postblock/hello_to_authors.exp +0 -1
  232. data/test/blackbox/postblock/hello_to_authors.tpl +0 -1
  233. data/test/blackbox/poststring/hello.exp +0 -1
  234. data/test/blackbox/poststring/hello.tpl +0 -1
  235. data/test/blackbox/test_all.rb +0 -70
  236. data/test/standard_dialects/ruby/data.rb +0 -7
  237. data/test/standard_dialects/ruby/inclusion.exp +0 -6
  238. data/test/standard_dialects/ruby/inclusion.tpl +0 -6
  239. data/test/standard_dialects/test_all.rb +0 -29
  240. data/test/standard_dialects/yaml/assumptions_test.rb +0 -13
  241. data/test/standard_dialects/yaml/data.rb +0 -3
  242. data/test/standard_dialects/yaml/inclusion_1.exp +0 -7
  243. data/test/standard_dialects/yaml/inclusion_1.tpl +0 -2
  244. data/test/standard_dialects/yaml/inclusion_2.exp +0 -5
  245. data/test/standard_dialects/yaml/inclusion_2.tpl +0 -3
  246. data/test/unit/test_all.rb +0 -9
  247. data/test/unit/wlang/anagram_bugs_test.rb +0 -111
  248. data/test/unit/wlang/basic_ruleset_test.rb +0 -52
  249. data/test/unit/wlang/buffering_ruleset_test.rb +0 -102
  250. data/test/unit/wlang/buffering_template1.wtpl +0 -1
  251. data/test/unit/wlang/buffering_template2.wtpl +0 -1
  252. data/test/unit/wlang/buffering_template3.wtpl +0 -1
  253. data/test/unit/wlang/buffering_template4.wtpl +0 -1
  254. data/test/unit/wlang/buffering_template5.wtpl +0 -1
  255. data/test/unit/wlang/context_ruleset_test.rb +0 -32
  256. data/test/unit/wlang/data.rb +0 -3
  257. data/test/unit/wlang/encoder_set_test.rb +0 -42
  258. data/test/unit/wlang/imperative_ruleset_test.rb +0 -107
  259. data/test/unit/wlang/intelligent_buffer_test.rb +0 -194
  260. data/test/unit/wlang/othersymbols_test.rb +0 -16
  261. data/test/unit/wlang/parser_test.rb +0 -88
  262. data/test/unit/wlang/plain_text_dialect_test.rb +0 -21
  263. data/test/unit/wlang/ruby_dialect_test.rb +0 -100
  264. data/test/unit/wlang/ruby_expected.rb +0 -3
  265. data/test/unit/wlang/ruby_template.wrb +0 -3
  266. data/test/unit/wlang/ruleset_utils_test.rb +0 -245
  267. data/test/unit/wlang/specification_examples_test.rb +0 -54
  268. data/test/unit/wlang/test_utils.rb +0 -25
  269. data/test/unit/wlang/wlang_test.rb +0 -80
@@ -1,8 +1,8 @@
1
1
  # Installs rake tasks for gemming and packaging
2
2
  #
3
- # This file installs the 'rake package', 'rake gem' tasks and associates
4
- # (clobber_package, repackage, ...). It is automatically generated by Noe
5
- # from your .noespec file, and should therefore be configured there, under
3
+ # This file installs the 'rake package', 'rake gem' tasks and associates
4
+ # (clobber_package, repackage, ...). It is automatically generated by Noe
5
+ # from your .noespec file, and should therefore be configured there, under
6
6
  # the variables/rake_tasks/gem entry, as illustrated below:
7
7
  #
8
8
  # variables:
@@ -15,9 +15,9 @@
15
15
  # need_zip: false
16
16
  # ...
17
17
  #
18
- # If you have specific needs requiring manual intervention on this file,
18
+ # If you have specific needs requiring manual intervention on this file,
19
19
  # don't forget to set safe-override to false in your noe specification:
20
- #
20
+ #
21
21
  # template-info:
22
22
  # manifest:
23
23
  # tasks/gem.rake:
@@ -25,35 +25,40 @@
25
25
  #
26
26
  begin
27
27
  require 'rubygems/package_task'
28
- Gem::PackageTask.new($gemspec) do |t|
28
+
29
+ # Dynamically load the gem spec
30
+ gemspec_file = File.expand_path('../../wlang.gemspec', __FILE__)
31
+ gemspec = Kernel.eval(File.read(gemspec_file))
32
+
33
+ Gem::PackageTask.new(gemspec) do |t|
29
34
 
30
35
  # Name of the package
31
- t.name = $gemspec.name
36
+ t.name = gemspec.name
32
37
 
33
38
  # Version of the package
34
- t.version = $gemspec.version
35
-
39
+ t.version = gemspec.version
40
+
36
41
  # Directory used to store the package files
37
42
  t.package_dir = "pkg"
38
-
43
+
39
44
  # True if a gzipped tar file (tgz) should be produced
40
45
  t.need_tar = false
41
-
46
+
42
47
  # True if a gzipped tar file (tar.gz) should be produced
43
48
  t.need_tar_gz = false
44
-
49
+
45
50
  # True if a bzip2'd tar file (tar.bz2) should be produced
46
51
  t.need_tar_bz2 = false
47
-
52
+
48
53
  # True if a zip file should be produced (default is false)
49
54
  t.need_zip = false
50
-
55
+
51
56
  # List of files to be included in the package.
52
- t.package_files = $gemspec.files
53
-
57
+ t.package_files = gemspec.files
58
+
54
59
  # Tar command for gzipped or bzip2ed archives.
55
60
  t.tar_command = "tar"
56
-
61
+
57
62
  # Zip command for zipped archives.
58
63
  t.zip_command = "zip"
59
64
 
@@ -1,8 +1,8 @@
1
1
  # Installs a rake task for for running examples written using rspec.
2
2
  #
3
3
  # This file installs the 'rake spec_test' (aliased as 'rake spec') as well as
4
- # extends 'rake test' to run spec tests, if any. It is automatically generated
5
- # by Noe from your .noespec file, and should therefore be configured there,
4
+ # extends 'rake test' to run spec tests, if any. It is automatically generated
5
+ # by Noe from your .noespec file, and should therefore be configured there,
6
6
  # under the variables/rake_tasks/spec_test entry, as illustrated below:
7
7
  #
8
8
  # variables:
@@ -13,16 +13,16 @@
13
13
  # rspec_opts: [--color, --backtrace]
14
14
  # ...
15
15
  #
16
- # If you have specific needs requiring manual intervention on this file,
16
+ # If you have specific needs requiring manual intervention on this file,
17
17
  # don't forget to set safe-override to false in your noe specification:
18
- #
18
+ #
19
19
  # template-info:
20
20
  # manifest:
21
21
  # tasks/spec_test.rake:
22
22
  # safe-override: false
23
23
  #
24
- # This file has been written to conform to RSpec v2.4.0. More information about
25
- # rspec and options of the rake task defined below can be found on
24
+ # This file has been written to conform to RSpec v2.4.0. More information about
25
+ # rspec and options of the rake task defined below can be found on
26
26
  # http://relishapp.com/rspec
27
27
  #
28
28
  begin
@@ -30,17 +30,9 @@ begin
30
30
  desc "Run RSpec code examples"
31
31
  RSpec::Core::RakeTask.new(:spec_test) do |t|
32
32
  # Glob pattern to match files.
33
- t.pattern = "spec/*.spec"
34
-
35
- # By default, if there is a Gemfile, the generated command will include
36
- # 'bundle exec'. Set this to true to ignore the presence of a Gemfile,
37
- # and not add 'bundle exec' to the command.
38
- t.skip_bundler = false
39
-
40
- # Name of Gemfile to use
41
- t.gemfile = "Gemfile"
33
+ t.pattern = "spec/**/test_*.rb"
42
34
 
43
- # Whether or not to fail Rake when an error occurs (typically when
35
+ # Whether or not to fail Rake when an error occurs (typically when
44
36
  # examples fail).
45
37
  t.fail_on_error = true
46
38
 
@@ -60,7 +52,7 @@ begin
60
52
  # Command line options to pass to rcov. See 'rcov --help' about this
61
53
  t.rcov_opts = []
62
54
 
63
- # Command line options to pass to ruby. See 'ruby --help' about this
55
+ # Command line options to pass to ruby. See 'ruby --help' about this
64
56
  t.ruby_opts = []
65
57
 
66
58
  # Path to rspec
@@ -1,8 +1,8 @@
1
1
  # Installs a rake task for for running unit tests.
2
2
  #
3
- # This file installs the 'rake unit_test' and extends 'rake test' to run unit
4
- # tests, if any. It is automatically generated by Noe from your .noespec file,
5
- # and should therefore be configured there, under the variables/rake_tasks/unit_test
3
+ # This file installs the 'rake unit_test' and extends 'rake test' to run unit
4
+ # tests, if any. It is automatically generated by Noe from your .noespec file,
5
+ # and should therefore be configured there, under the variables/rake_tasks/unit_test
6
6
  # entry, as illustrated below:
7
7
  #
8
8
  # variables:
@@ -13,15 +13,15 @@
13
13
  # warning: false
14
14
  # ...
15
15
  #
16
- # If you have specific needs requiring manual intervention on this file,
16
+ # If you have specific needs requiring manual intervention on this file,
17
17
  # don't forget to set safe-override to false in your noe specification:
18
- #
18
+ #
19
19
  # template-info:
20
20
  # manifest:
21
21
  # tasks/unit_test.rake:
22
22
  # safe-override: false
23
23
  #
24
- # More info about the TestTask and its options can be found on
24
+ # More info about the TestTask and its options can be found on
25
25
  # http://rake.rubyforge.org/classes/Rake/TestTask.html
26
26
  #
27
27
  begin
@@ -36,7 +36,7 @@ begin
36
36
  # True if verbose test output desired. (default is false)
37
37
  t.verbose = false
38
38
 
39
- # Test options passed to the test suite. An explicit TESTOPTS=opts
39
+ # Test options passed to the test suite. An explicit TESTOPTS=opts
40
40
  # on the command line will override this. (default is NONE)
41
41
  t.options = nil
42
42
 
@@ -45,17 +45,17 @@ begin
45
45
  t.warning = false
46
46
 
47
47
  # Glob pattern to match test files. (default is 'test/test*.rb')
48
- t.pattern = nil
48
+ t.pattern = "test/test_*.rb"
49
49
 
50
50
  # Style of test loader to use. Options are:
51
51
  #
52
52
  # * :rake -- Rake provided test loading script (default).
53
53
  # * :testrb -- Ruby provided test loading script.
54
54
  # * :direct -- Load tests using command line loader.
55
- #
55
+ #
56
56
  t.loader = :rake
57
57
 
58
- # Array of commandline options to pass to ruby when running test
58
+ # Array of commandline options to pass to ruby when running test
59
59
  # loader.
60
60
  t.ruby_opts = []
61
61
 
@@ -63,7 +63,7 @@ begin
63
63
  # test. +list+ is expected to be an array of file names (a
64
64
  # FileList is acceptable). If both +pattern+ and +test_files+ are
65
65
  # used, then the list of test files is the union of the two.
66
- t.test_files = ["test/unit/test_all.rb", "test/blackbox/test_all.rb", "test/standard_dialects/test_all.rb", "test/standard_dialects/**/*_test.rb"]
66
+ t.test_files = nil
67
67
 
68
68
  end
69
69
  rescue LoadError => ex
@@ -74,4 +74,3 @@ ensure
74
74
  desc "Run all tests"
75
75
  task :test => [:unit_test]
76
76
  end
77
-
@@ -1,7 +1,7 @@
1
1
  # Installs a rake task to generate API documentation using yard.
2
2
  #
3
- # This file installs the 'rake yard' task. It is automatically generated by Noe from
4
- # your .noespec file, and should therefore be configured there, under the
3
+ # This file installs the 'rake yard' task. It is automatically generated by Noe from
4
+ # your .noespec file, and should therefore be configured there, under the
5
5
  # variables/rake_tasks/yard entry, as illustrated below:
6
6
  #
7
7
  # variables:
@@ -11,15 +11,15 @@
11
11
  # options: []
12
12
  # ...
13
13
  #
14
- # If you have specific needs requiring manual intervention on this file,
14
+ # If you have specific needs requiring manual intervention on this file,
15
15
  # don't forget to set safe-override to false in your noe specification:
16
- #
16
+ #
17
17
  # template-info:
18
18
  # manifest:
19
19
  # tasks/yard.rake:
20
20
  # safe-override: false
21
21
  #
22
- # This file has been written to conform to yard v0.6.4. More information about
22
+ # This file has been written to conform to yard v0.6.4. More information about
23
23
  # yard and the rake task installed below can be found on http://yardoc.org/
24
24
  #
25
25
  begin
@@ -28,20 +28,20 @@ begin
28
28
  YARD::Rake::YardocTask.new(:yard) do |t|
29
29
  # Array of options passed to yardoc commandline. See 'yardoc --help' about this
30
30
  t.options = ["--output-dir", "doc/api", "-", "README.md", "CHANGELOG.md", "LICENCE.md"]
31
-
32
- # Array of ruby source files (and any extra documentation files
31
+
32
+ # Array of ruby source files (and any extra documentation files
33
33
  # separated by '-')
34
34
  t.files = ["lib/**/*.rb"]
35
-
35
+
36
36
  # A proc to call before running the task
37
37
  # t.before = proc{ }
38
-
38
+
39
39
  # A proc to call after running the task
40
40
  # r.after = proc{ }
41
-
42
- # An optional lambda to run against all objects being generated.
43
- # Any object that the lambda returns false for will be excluded
44
- # from documentation.
41
+
42
+ # An optional lambda to run against all objects being generated.
43
+ # Any object that the lambda returns false for will be excluded
44
+ # from documentation.
45
45
  # t.verifier = lambda{|obj| true}
46
46
  end
47
47
  rescue LoadError
@@ -1,4 +1,4 @@
1
- # We require your library, mainly to have access to the VERSION number.
1
+ # We require your library, mainly to have access to the VERSION number.
2
2
  # Feel free to set $version manually.
3
3
  $LOAD_PATH.unshift File.expand_path('../lib', __FILE__)
4
4
  require "wlang/version"
@@ -9,15 +9,15 @@ $version = WLang::Version.to_s
9
9
  # should be correctly packaged given what you have described in the .noespec file.
10
10
  #
11
11
  Gem::Specification.new do |s|
12
-
12
+
13
13
  ################################################################### ABOUT YOUR GEM
14
-
15
- # Gem name (required)
14
+
15
+ # Gem name (required)
16
16
  s.name = "wlang"
17
-
17
+
18
18
  # Gem version (required)
19
19
  s.version = $version
20
-
20
+
21
21
  # A short summary of this gem
22
22
  #
23
23
  # This is displayed in `gem list -d`.
@@ -28,7 +28,7 @@ Gem::Specification.new do |s|
28
28
  # The description should be more detailed than the summary. For example,
29
29
  # you might wish to copy the entire README into the description.
30
30
  s.description = "WLang is a general-purpose *code generation*/*templating engine*. It's main aim is to help you generating\nweb pages, sql queries, ruby code (that is, generating code in general) without having to worry too much \nabout html entities encoding, sql back quoting, string escaping and the like. WLang proposes a generic \nengine that you can extend to fit your needs. It also proposes standard instantiations of this engine \nfor common tasks such as creating SQL queries, instantiating web pages, and so on."
31
-
31
+
32
32
  # The URL of this gem home page (optional)
33
33
  s.homepage = "http://github.com/blambeau/wlang"
34
34
 
@@ -38,7 +38,7 @@ Gem::Specification.new do |s|
38
38
  # you know what you do!
39
39
  #
40
40
  # s.date = Time.now.strftime('%Y-%m-%d')
41
-
41
+
42
42
  # The license(s) for the library. Each license must be a short name, no
43
43
  # more than 64 characters.
44
44
  #
@@ -49,35 +49,35 @@ Gem::Specification.new do |s|
49
49
  # s.rubyforge_project = nil
50
50
 
51
51
  ################################################################### ABOUT THE AUTHORS
52
-
52
+
53
53
  # The list of author names who wrote this gem.
54
54
  #
55
55
  # If you are providing multiple authors and multiple emails they should be
56
56
  # in the same order.
57
- #
57
+ #
58
58
  s.authors = ["Bernard Lambeau", "Louis Lambeau"]
59
-
59
+
60
60
  # Contact emails for this gem
61
61
  #
62
62
  # If you are providing multiple authors and multiple emails they should be
63
63
  # in the same order.
64
64
  #
65
- # NOTE: Somewhat strangly this attribute is always singular!
65
+ # NOTE: Somewhat strangly this attribute is always singular!
66
66
  # Don't replace by s.emails = ...
67
67
  s.email = ["blambeau@gmail.com", "llambeau@gmail.com"]
68
68
 
69
69
  ################################################################### PATHS, FILES, BINARIES
70
-
71
- # Paths in the gem to add to $LOAD_PATH when this gem is
70
+
71
+ # Paths in the gem to add to $LOAD_PATH when this gem is
72
72
  # activated (required).
73
73
  #
74
74
  # The default 'lib' is typically sufficient.
75
75
  s.require_paths = ["lib"]
76
-
76
+
77
77
  # Files included in this gem.
78
78
  #
79
79
  # By default, we take all files included in the Manifest.txt file on root
80
- # of the project. Entries of the manifest are interpreted as Dir[...]
80
+ # of the project. Entries of the manifest are interpreted as Dir[...]
81
81
  # patterns so that lazy people may use wilcards like lib/**/*
82
82
  #
83
83
  here = File.expand_path(File.dirname(__FILE__))
@@ -107,7 +107,7 @@ Gem::Specification.new do |s|
107
107
  # <= Less than or equal to
108
108
  # ~> Approximately greater than
109
109
  #
110
- # Don't forget to have a look at http://lmgtfy.com/?q=Ruby+Versioning+Policies
110
+ # Don't forget to have a look at http://lmgtfy.com/?q=Ruby+Versioning+Policies
111
111
  # for setting your gem version.
112
112
  #
113
113
  # For your requirements to other gems, remember that
@@ -119,19 +119,23 @@ Gem::Specification.new do |s|
119
119
 
120
120
  #
121
121
  # One call to add_dependency('gem_name', 'gem version requirement') for each
122
- # runtime dependency. These gems will be installed with your gem.
122
+ # runtime dependency. These gems will be installed with your gem.
123
123
  # One call to add_development_dependency('gem_name', 'gem version requirement')
124
124
  # for each development dependency. These gems are required for developers
125
125
  #
126
- s.add_development_dependency("rake", "~> 0.8.7")
126
+ s.add_development_dependency("ruby-prof", "~> 0.11.2")
127
+ s.add_development_dependency("mustache", "~> 0.99.4")
128
+ s.add_development_dependency("rake", "~> 0.9.2")
127
129
  s.add_development_dependency("bundler", "~> 1.0")
128
- s.add_development_dependency("rspec", "~> 2.4.0")
129
- s.add_development_dependency("yard", "~> 0.6.4")
130
- s.add_development_dependency("bluecloth", "~> 2.0.9")
131
- s.add_development_dependency("rdoc", ">= 0")
132
- s.add_development_dependency("coderay", ">= 0")
133
- s.add_development_dependency("RedCloth", ">= 0")
134
-
130
+ s.add_development_dependency("rspec", "~> 2.10.0")
131
+ s.add_development_dependency("epath", "~> 0.1.0")
132
+ s.add_development_dependency("yard", "~> 0.8.1")
133
+ s.add_development_dependency("bluecloth", "~> 2.2.0")
134
+ s.add_dependency("citrus", "~> 2.4.1")
135
+ s.add_dependency("temple", "~> 0.4.0")
136
+ s.add_dependency("backports", "~> 2.6.1")
137
+ s.add_dependency("quickl", "~> 0.4.3")
138
+ s.add_dependency("awesome_print", "~> 1.0.2")
135
139
 
136
140
  # The version of ruby required by this gem
137
141
  #
@@ -147,18 +151,18 @@ Gem::Specification.new do |s|
147
151
  #
148
152
  # s.platform = nil
149
153
 
150
- # Extensions to build when installing the gem.
154
+ # Extensions to build when installing the gem.
151
155
  #
152
- # Valid types of extensions are extconf.rb files, configure scripts
156
+ # Valid types of extensions are extconf.rb files, configure scripts
153
157
  # and rakefiles or mkrf_conf files.
154
158
  #
155
159
  s.extensions = []
156
-
157
- # External (to RubyGems) requirements that must be met for this gem to work.
160
+
161
+ # External (to RubyGems) requirements that must be met for this gem to work.
158
162
  # It’s simply information for the user.
159
163
  #
160
164
  s.requirements = nil
161
-
165
+
162
166
  # A message that gets displayed after the gem is installed
163
167
  #
164
168
  # Uncomment and set this if you want to say something to the user
@@ -176,7 +180,7 @@ Gem::Specification.new do |s|
176
180
  # details.
177
181
  #
178
182
  # s.cert_chain = []
179
-
183
+
180
184
  ################################################################### RDOC
181
185
 
182
186
  # An ARGV style array of options to RDoc
@@ -1,54 +1,46 @@
1
- # Noe template for ruby gem libraries (https://github.com/blambeau/noe) - short version
2
- # Run 'noe show-spec' and 'noe help show-spec' for additional details.
3
-
4
- # Don't remove this entry!
5
1
  template-info:
6
- name: "ruby"
7
- version: 1.1.0
8
-
9
- # Update to match your own configuration.
2
+ name: "rubygem.noe"
3
+ version: 1.7.4
4
+ links:
5
+ source: https://github.com/blambeau/noe
6
+ manifest:
7
+ lib/__lower__/loader.rb:
8
+ safe-override: false
10
9
  variables:
11
10
  lower:
12
11
  wlang
13
12
  upper:
14
13
  WLang
15
14
  version:
16
- 0.10.2
15
+ 2.0.0.beta
17
16
  summary: |-
18
17
  WLang is a powerful code generation and templating engine
19
18
  description: |-
20
- WLang is a general-purpose *code generation*/*templating engine*. It's main aim is to help you generating
21
- web pages, sql queries, ruby code (that is, generating code in general) without having to worry too much
22
- about html entities encoding, sql back quoting, string escaping and the like. WLang proposes a generic
23
- engine that you can extend to fit your needs. It also proposes standard instantiations of this engine
24
- for common tasks such as creating SQL queries, instantiating web pages, and so on.
19
+ WLang is a general-purpose *code generation*/*templating engine*. It's main aim is to
20
+ help you generating web pages, sql queries, ruby code (that is, generating text in
21
+ general) without having to worry too much about html entities encoding, sql back
22
+ quoting, string escaping and the like. WLang proposes a generic engine that you can
23
+ easily extend to fit your needs. It also proposes standard instantiations of this
24
+ engine for common tasks such as rendering HTML web pages.
25
25
  authors:
26
26
  - {name: Bernard Lambeau, email: blambeau@gmail.com}
27
- - {name: Louis Lambeau, email: llambeau@gmail.com}
27
+ - {name: Louis Lambeau, email: llambeau@gmail.com}
28
28
  links:
29
29
  - http://github.com/blambeau/wlang
30
30
  - http://rubygems.org/gems/wlang
31
31
  - http://blambeau.github.com/wlang
32
32
  - http://revision-zero.org/wlang
33
33
  dependencies:
34
- - {name: rake, version: "~> 0.8.7", groups: [development]}
34
+ - {name: citrus, version: "~> 2.4.1", groups: [runtime]}
35
+ - {name: temple, version: "~> 0.4.0", groups: [runtime]}
36
+ - {name: backports, version: "~> 2.6.1", groups: [runtime]}
37
+ - {name: quickl, version: "~> 0.4.3", groups: [runtime]}
38
+ - {name: awesome_print, version: "~> 1.0.2", groups: [runtime]}
39
+ - {name: ruby-prof, version: "~> 0.11.2", groups: [profiling]}
40
+ - {name: mustache, version: "~> 0.99.4", groups: [profiling]}
41
+ - {name: rake, version: "~> 0.9.2", groups: [development]}
35
42
  - {name: bundler, version: "~> 1.0", groups: [development]}
36
- - {name: rspec, version: "~> 2.4.0", groups: [development]}
37
- - {name: yard, version: "~> 0.6.4", groups: [development]}
38
- - {name: bluecloth, version: "~> 2.0.9", groups: [development]}
39
- #
40
- - {name: rdoc, version: ">= 0", groups: [development]}
41
- - {name: coderay, version: ">= 0", groups: [development]}
42
- - {name: RedCloth, version: ">= 0", groups: [development]}
43
- rake_tasks:
44
- debug_mail:
45
- nb_changelog_sections: 2
46
- spec_test:
47
- pattern: 'spec/*.spec'
48
- unit_test:
49
- pattern:
50
- test_files:
51
- - test/unit/test_all.rb
52
- - test/blackbox/test_all.rb
53
- - test/standard_dialects/test_all.rb
54
- - test/standard_dialects/**/*_test.rb
43
+ - {name: rspec, version: "~> 2.10.0", groups: [development]}
44
+ - {name: epath, version: "~> 0.1.0", groups: [development]}
45
+ - {name: yard, version: "~> 0.8.1", groups: [development]}
46
+ - {name: bluecloth, version: "~> 2.2.0", groups: [development]}