hyper-pro-gem 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (380) hide show
  1. checksums.yaml +7 -0
  2. data/hyper-pro-gem.gemspec +12 -0
  3. data/yard-0.9.44/CHANGELOG.md +983 -0
  4. data/yard-0.9.44/LEGAL +94 -0
  5. data/yard-0.9.44/LICENSE +22 -0
  6. data/yard-0.9.44/README.md +329 -0
  7. data/yard-0.9.44/bin/yard +13 -0
  8. data/yard-0.9.44/bin/yardoc +13 -0
  9. data/yard-0.9.44/bin/yri +13 -0
  10. data/yard-0.9.44/docs/CodeObjects.md +115 -0
  11. data/yard-0.9.44/docs/GettingStarted.md +705 -0
  12. data/yard-0.9.44/docs/Handlers.md +152 -0
  13. data/yard-0.9.44/docs/Overview.md +61 -0
  14. data/yard-0.9.44/docs/Parser.md +166 -0
  15. data/yard-0.9.44/docs/Tags.md +304 -0
  16. data/yard-0.9.44/docs/TagsArch.md +123 -0
  17. data/yard-0.9.44/docs/Templates.md +497 -0
  18. data/yard-0.9.44/docs/WhatsNew.md +1297 -0
  19. data/yard-0.9.44/docs/images/code-objects-class-diagram.png +0 -0
  20. data/yard-0.9.44/docs/images/handlers-class-diagram.png +0 -0
  21. data/yard-0.9.44/docs/images/overview-class-diagram.png +0 -0
  22. data/yard-0.9.44/docs/images/parser-class-diagram.png +0 -0
  23. data/yard-0.9.44/docs/images/tags-class-diagram.png +0 -0
  24. data/yard-0.9.44/docs/templates/default/fulldoc/html/full_list_tag.erb +9 -0
  25. data/yard-0.9.44/docs/templates/default/fulldoc/html/setup.rb +6 -0
  26. data/yard-0.9.44/docs/templates/default/layout/html/setup.rb +9 -0
  27. data/yard-0.9.44/docs/templates/default/layout/html/tag_list.erb +11 -0
  28. data/yard-0.9.44/docs/templates/default/yard_tags/html/list.erb +18 -0
  29. data/yard-0.9.44/docs/templates/default/yard_tags/html/setup.rb +26 -0
  30. data/yard-0.9.44/docs/templates/plugin.rb +70 -0
  31. data/yard-0.9.44/lib/rubygems_plugin.rb +9 -0
  32. data/yard-0.9.44/lib/yard/autoload.rb +328 -0
  33. data/yard-0.9.44/lib/yard/cli/command.rb +85 -0
  34. data/yard-0.9.44/lib/yard/cli/command_parser.rb +93 -0
  35. data/yard-0.9.44/lib/yard/cli/config.rb +198 -0
  36. data/yard-0.9.44/lib/yard/cli/diff.rb +278 -0
  37. data/yard-0.9.44/lib/yard/cli/display.rb +69 -0
  38. data/yard-0.9.44/lib/yard/cli/gems.rb +84 -0
  39. data/yard-0.9.44/lib/yard/cli/graph.rb +125 -0
  40. data/yard-0.9.44/lib/yard/cli/help.rb +20 -0
  41. data/yard-0.9.44/lib/yard/cli/i18n.rb +70 -0
  42. data/yard-0.9.44/lib/yard/cli/list.rb +23 -0
  43. data/yard-0.9.44/lib/yard/cli/markup_types.rb +32 -0
  44. data/yard-0.9.44/lib/yard/cli/server.rb +266 -0
  45. data/yard-0.9.44/lib/yard/cli/stats.rb +234 -0
  46. data/yard-0.9.44/lib/yard/cli/yardoc.rb +791 -0
  47. data/yard-0.9.44/lib/yard/cli/yardopts_command.rb +110 -0
  48. data/yard-0.9.44/lib/yard/cli/yri.rb +215 -0
  49. data/yard-0.9.44/lib/yard/code_objects/base.rb +626 -0
  50. data/yard-0.9.44/lib/yard/code_objects/class_object.rb +146 -0
  51. data/yard-0.9.44/lib/yard/code_objects/class_variable_object.rb +11 -0
  52. data/yard-0.9.44/lib/yard/code_objects/constant_object.rb +16 -0
  53. data/yard-0.9.44/lib/yard/code_objects/extended_method_object.rb +24 -0
  54. data/yard-0.9.44/lib/yard/code_objects/extra_file_object.rb +135 -0
  55. data/yard-0.9.44/lib/yard/code_objects/macro_object.rb +171 -0
  56. data/yard-0.9.44/lib/yard/code_objects/method_object.rb +196 -0
  57. data/yard-0.9.44/lib/yard/code_objects/module_object.rb +21 -0
  58. data/yard-0.9.44/lib/yard/code_objects/namespace_mapper.rb +141 -0
  59. data/yard-0.9.44/lib/yard/code_objects/namespace_object.rb +200 -0
  60. data/yard-0.9.44/lib/yard/code_objects/proxy.rb +245 -0
  61. data/yard-0.9.44/lib/yard/code_objects/root_object.rb +19 -0
  62. data/yard-0.9.44/lib/yard/config.rb +274 -0
  63. data/yard-0.9.44/lib/yard/core_ext/array.rb +16 -0
  64. data/yard-0.9.44/lib/yard/core_ext/file.rb +69 -0
  65. data/yard-0.9.44/lib/yard/core_ext/hash.rb +16 -0
  66. data/yard-0.9.44/lib/yard/core_ext/insertion.rb +63 -0
  67. data/yard-0.9.44/lib/yard/core_ext/module.rb +11 -0
  68. data/yard-0.9.44/lib/yard/core_ext/string.rb +68 -0
  69. data/yard-0.9.44/lib/yard/core_ext/symbol_hash.rb +75 -0
  70. data/yard-0.9.44/lib/yard/docstring.rb +386 -0
  71. data/yard-0.9.44/lib/yard/docstring_parser.rb +344 -0
  72. data/yard-0.9.44/lib/yard/gem_index.rb +29 -0
  73. data/yard-0.9.44/lib/yard/globals.rb +22 -0
  74. data/yard-0.9.44/lib/yard/handlers/base.rb +617 -0
  75. data/yard-0.9.44/lib/yard/handlers/c/alias_handler.rb +16 -0
  76. data/yard-0.9.44/lib/yard/handlers/c/attribute_handler.rb +13 -0
  77. data/yard-0.9.44/lib/yard/handlers/c/base.rb +164 -0
  78. data/yard-0.9.44/lib/yard/handlers/c/class_handler.rb +27 -0
  79. data/yard-0.9.44/lib/yard/handlers/c/constant_handler.rb +13 -0
  80. data/yard-0.9.44/lib/yard/handlers/c/handler_methods.rb +212 -0
  81. data/yard-0.9.44/lib/yard/handlers/c/init_handler.rb +20 -0
  82. data/yard-0.9.44/lib/yard/handlers/c/method_handler.rb +45 -0
  83. data/yard-0.9.44/lib/yard/handlers/c/mixin_handler.rb +21 -0
  84. data/yard-0.9.44/lib/yard/handlers/c/module_handler.rb +17 -0
  85. data/yard-0.9.44/lib/yard/handlers/c/override_comment_handler.rb +31 -0
  86. data/yard-0.9.44/lib/yard/handlers/c/path_handler.rb +11 -0
  87. data/yard-0.9.44/lib/yard/handlers/c/struct_handler.rb +13 -0
  88. data/yard-0.9.44/lib/yard/handlers/c/symbol_handler.rb +8 -0
  89. data/yard-0.9.44/lib/yard/handlers/common/method_handler.rb +19 -0
  90. data/yard-0.9.44/lib/yard/handlers/processor.rb +200 -0
  91. data/yard-0.9.44/lib/yard/handlers/rbs/attribute_handler.rb +79 -0
  92. data/yard-0.9.44/lib/yard/handlers/rbs/base.rb +38 -0
  93. data/yard-0.9.44/lib/yard/handlers/rbs/constant_handler.rb +18 -0
  94. data/yard-0.9.44/lib/yard/handlers/rbs/method_handler.rb +327 -0
  95. data/yard-0.9.44/lib/yard/handlers/rbs/mixin_handler.rb +20 -0
  96. data/yard-0.9.44/lib/yard/handlers/rbs/namespace_handler.rb +26 -0
  97. data/yard-0.9.44/lib/yard/handlers/ruby/alias_handler.rb +45 -0
  98. data/yard-0.9.44/lib/yard/handlers/ruby/attribute_handler.rb +90 -0
  99. data/yard-0.9.44/lib/yard/handlers/ruby/base.rb +165 -0
  100. data/yard-0.9.44/lib/yard/handlers/ruby/class_condition_handler.rb +92 -0
  101. data/yard-0.9.44/lib/yard/handlers/ruby/class_handler.rb +119 -0
  102. data/yard-0.9.44/lib/yard/handlers/ruby/class_variable_handler.rb +17 -0
  103. data/yard-0.9.44/lib/yard/handlers/ruby/comment_handler.rb +10 -0
  104. data/yard-0.9.44/lib/yard/handlers/ruby/constant_handler.rb +73 -0
  105. data/yard-0.9.44/lib/yard/handlers/ruby/decorator_handler_methods.rb +123 -0
  106. data/yard-0.9.44/lib/yard/handlers/ruby/dsl_handler.rb +15 -0
  107. data/yard-0.9.44/lib/yard/handlers/ruby/dsl_handler_methods.rb +96 -0
  108. data/yard-0.9.44/lib/yard/handlers/ruby/exception_handler.rb +27 -0
  109. data/yard-0.9.44/lib/yard/handlers/ruby/extend_handler.rb +22 -0
  110. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/alias_handler.rb +37 -0
  111. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/attribute_handler.rb +65 -0
  112. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/base.rb +245 -0
  113. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/class_condition_handler.rb +83 -0
  114. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/class_handler.rb +113 -0
  115. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/class_variable_handler.rb +15 -0
  116. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/comment_handler.rb +10 -0
  117. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/constant_handler.rb +29 -0
  118. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/dsl_handler.rb +17 -0
  119. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/exception_handler.rb +13 -0
  120. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/extend_handler.rb +21 -0
  121. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/method_handler.rb +90 -0
  122. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/mixin_handler.rb +39 -0
  123. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/module_function_handler.rb +19 -0
  124. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/module_handler.rb +12 -0
  125. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/private_class_method_handler.rb +22 -0
  126. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/private_constant_handler.rb +22 -0
  127. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/visibility_handler.rb +18 -0
  128. data/yard-0.9.44/lib/yard/handlers/ruby/legacy/yield_handler.rb +29 -0
  129. data/yard-0.9.44/lib/yard/handlers/ruby/method_condition_handler.rb +9 -0
  130. data/yard-0.9.44/lib/yard/handlers/ruby/method_handler.rb +104 -0
  131. data/yard-0.9.44/lib/yard/handlers/ruby/mixin_handler.rb +61 -0
  132. data/yard-0.9.44/lib/yard/handlers/ruby/module_function_handler.rb +39 -0
  133. data/yard-0.9.44/lib/yard/handlers/ruby/module_handler.rb +12 -0
  134. data/yard-0.9.44/lib/yard/handlers/ruby/private_class_method_handler.rb +14 -0
  135. data/yard-0.9.44/lib/yard/handlers/ruby/private_constant_handler.rb +43 -0
  136. data/yard-0.9.44/lib/yard/handlers/ruby/public_class_method_handler.rb +14 -0
  137. data/yard-0.9.44/lib/yard/handlers/ruby/struct_handler_methods.rb +143 -0
  138. data/yard-0.9.44/lib/yard/handlers/ruby/visibility_handler.rb +35 -0
  139. data/yard-0.9.44/lib/yard/handlers/ruby/yield_handler.rb +31 -0
  140. data/yard-0.9.44/lib/yard/i18n/locale.rb +67 -0
  141. data/yard-0.9.44/lib/yard/i18n/message.rb +57 -0
  142. data/yard-0.9.44/lib/yard/i18n/messages.rb +56 -0
  143. data/yard-0.9.44/lib/yard/i18n/po_parser.rb +61 -0
  144. data/yard-0.9.44/lib/yard/i18n/pot_generator.rb +290 -0
  145. data/yard-0.9.44/lib/yard/i18n/text.rb +173 -0
  146. data/yard-0.9.44/lib/yard/logging.rb +260 -0
  147. data/yard-0.9.44/lib/yard/open_struct.rb +67 -0
  148. data/yard-0.9.44/lib/yard/options.rb +217 -0
  149. data/yard-0.9.44/lib/yard/parser/base.rb +57 -0
  150. data/yard-0.9.44/lib/yard/parser/c/c_parser.rb +235 -0
  151. data/yard-0.9.44/lib/yard/parser/c/comment_parser.rb +134 -0
  152. data/yard-0.9.44/lib/yard/parser/c/statement.rb +66 -0
  153. data/yard-0.9.44/lib/yard/parser/rbs/rbs_parser.rb +325 -0
  154. data/yard-0.9.44/lib/yard/parser/rbs/statement.rb +75 -0
  155. data/yard-0.9.44/lib/yard/parser/ruby/ast_node.rb +559 -0
  156. data/yard-0.9.44/lib/yard/parser/ruby/legacy/irb/slex.rb +294 -0
  157. data/yard-0.9.44/lib/yard/parser/ruby/legacy/ruby_lex.rb +1360 -0
  158. data/yard-0.9.44/lib/yard/parser/ruby/legacy/ruby_parser.rb +32 -0
  159. data/yard-0.9.44/lib/yard/parser/ruby/legacy/statement.rb +68 -0
  160. data/yard-0.9.44/lib/yard/parser/ruby/legacy/statement_list.rb +394 -0
  161. data/yard-0.9.44/lib/yard/parser/ruby/legacy/token_list.rb +74 -0
  162. data/yard-0.9.44/lib/yard/parser/ruby/ruby_parser.rb +792 -0
  163. data/yard-0.9.44/lib/yard/parser/ruby/token_resolver.rb +158 -0
  164. data/yard-0.9.44/lib/yard/parser/source_parser.rb +526 -0
  165. data/yard-0.9.44/lib/yard/rake/yardoc_task.rb +81 -0
  166. data/yard-0.9.44/lib/yard/registry.rb +439 -0
  167. data/yard-0.9.44/lib/yard/registry_resolver.rb +225 -0
  168. data/yard-0.9.44/lib/yard/registry_store.rb +342 -0
  169. data/yard-0.9.44/lib/yard/rubygems/backports/LICENSE.txt +57 -0
  170. data/yard-0.9.44/lib/yard/rubygems/backports/MIT.txt +20 -0
  171. data/yard-0.9.44/lib/yard/rubygems/backports/gem.rb +10 -0
  172. data/yard-0.9.44/lib/yard/rubygems/backports/source_index.rb +365 -0
  173. data/yard-0.9.44/lib/yard/rubygems/backports.rb +10 -0
  174. data/yard-0.9.44/lib/yard/rubygems/doc_manager.rb +90 -0
  175. data/yard-0.9.44/lib/yard/rubygems/hook.rb +197 -0
  176. data/yard-0.9.44/lib/yard/rubygems/specification.rb +50 -0
  177. data/yard-0.9.44/lib/yard/serializers/base.rb +83 -0
  178. data/yard-0.9.44/lib/yard/serializers/file_system_serializer.rb +123 -0
  179. data/yard-0.9.44/lib/yard/serializers/process_serializer.rb +24 -0
  180. data/yard-0.9.44/lib/yard/serializers/stdout_serializer.rb +34 -0
  181. data/yard-0.9.44/lib/yard/serializers/yardoc_serializer.rb +152 -0
  182. data/yard-0.9.44/lib/yard/server/adapter.rb +100 -0
  183. data/yard-0.9.44/lib/yard/server/commands/base.rb +203 -0
  184. data/yard-0.9.44/lib/yard/server/commands/display_file_command.rb +29 -0
  185. data/yard-0.9.44/lib/yard/server/commands/display_object_command.rb +65 -0
  186. data/yard-0.9.44/lib/yard/server/commands/frames_command.rb +16 -0
  187. data/yard-0.9.44/lib/yard/server/commands/library_command.rb +187 -0
  188. data/yard-0.9.44/lib/yard/server/commands/library_index_command.rb +28 -0
  189. data/yard-0.9.44/lib/yard/server/commands/list_command.rb +25 -0
  190. data/yard-0.9.44/lib/yard/server/commands/root_request_command.rb +15 -0
  191. data/yard-0.9.44/lib/yard/server/commands/search_command.rb +79 -0
  192. data/yard-0.9.44/lib/yard/server/commands/static_file_command.rb +23 -0
  193. data/yard-0.9.44/lib/yard/server/commands/static_file_helpers.rb +60 -0
  194. data/yard-0.9.44/lib/yard/server/doc_server_helper.rb +91 -0
  195. data/yard-0.9.44/lib/yard/server/doc_server_serializer.rb +39 -0
  196. data/yard-0.9.44/lib/yard/server/http_utils.rb +512 -0
  197. data/yard-0.9.44/lib/yard/server/library_version.rb +277 -0
  198. data/yard-0.9.44/lib/yard/server/rack_adapter.rb +97 -0
  199. data/yard-0.9.44/lib/yard/server/router.rb +187 -0
  200. data/yard-0.9.44/lib/yard/server/static_caching.rb +77 -0
  201. data/yard-0.9.44/lib/yard/server/templates/default/fulldoc/html/css/custom.css +207 -0
  202. data/yard-0.9.44/lib/yard/server/templates/default/fulldoc/html/images/processing.gif +0 -0
  203. data/yard-0.9.44/lib/yard/server/templates/default/fulldoc/html/js/autocomplete.js +203 -0
  204. data/yard-0.9.44/lib/yard/server/templates/default/layout/html/breadcrumb.erb +21 -0
  205. data/yard-0.9.44/lib/yard/server/templates/default/layout/html/script_setup.erb +7 -0
  206. data/yard-0.9.44/lib/yard/server/templates/default/layout/html/setup.rb +8 -0
  207. data/yard-0.9.44/lib/yard/server/templates/default/method_details/html/permalink.erb +6 -0
  208. data/yard-0.9.44/lib/yard/server/templates/default/method_details/html/setup.rb +5 -0
  209. data/yard-0.9.44/lib/yard/server/templates/doc_server/library_list/html/headers.erb +8 -0
  210. data/yard-0.9.44/lib/yard/server/templates/doc_server/library_list/html/library_list.erb +13 -0
  211. data/yard-0.9.44/lib/yard/server/templates/doc_server/library_list/html/listing.erb +13 -0
  212. data/yard-0.9.44/lib/yard/server/templates/doc_server/library_list/html/setup.rb +6 -0
  213. data/yard-0.9.44/lib/yard/server/templates/doc_server/library_list/html/title.erb +2 -0
  214. data/yard-0.9.44/lib/yard/server/templates/doc_server/processing/html/processing.erb +58 -0
  215. data/yard-0.9.44/lib/yard/server/templates/doc_server/processing/html/setup.rb +4 -0
  216. data/yard-0.9.44/lib/yard/server/templates/doc_server/search/html/search.erb +18 -0
  217. data/yard-0.9.44/lib/yard/server/templates/doc_server/search/html/setup.rb +9 -0
  218. data/yard-0.9.44/lib/yard/server/webrick_adapter.rb +45 -0
  219. data/yard-0.9.44/lib/yard/server.rb +13 -0
  220. data/yard-0.9.44/lib/yard/tags/default_factory.rb +192 -0
  221. data/yard-0.9.44/lib/yard/tags/default_tag.rb +13 -0
  222. data/yard-0.9.44/lib/yard/tags/directives.rb +631 -0
  223. data/yard-0.9.44/lib/yard/tags/library.rb +633 -0
  224. data/yard-0.9.44/lib/yard/tags/option_tag.rb +13 -0
  225. data/yard-0.9.44/lib/yard/tags/overload_tag.rb +72 -0
  226. data/yard-0.9.44/lib/yard/tags/ref_tag.rb +8 -0
  227. data/yard-0.9.44/lib/yard/tags/ref_tag_list.rb +28 -0
  228. data/yard-0.9.44/lib/yard/tags/tag.rb +72 -0
  229. data/yard-0.9.44/lib/yard/tags/tag_format_error.rb +7 -0
  230. data/yard-0.9.44/lib/yard/tags/types_explainer.rb +288 -0
  231. data/yard-0.9.44/lib/yard/templates/engine.rb +185 -0
  232. data/yard-0.9.44/lib/yard/templates/erb_cache.rb +23 -0
  233. data/yard-0.9.44/lib/yard/templates/helpers/base_helper.rb +215 -0
  234. data/yard-0.9.44/lib/yard/templates/helpers/filter_helper.rb +27 -0
  235. data/yard-0.9.44/lib/yard/templates/helpers/html_helper.rb +688 -0
  236. data/yard-0.9.44/lib/yard/templates/helpers/html_syntax_highlight_helper.rb +83 -0
  237. data/yard-0.9.44/lib/yard/templates/helpers/markup/html_entities.rb +2140 -0
  238. data/yard-0.9.44/lib/yard/templates/helpers/markup/hybrid_markdown.rb +2131 -0
  239. data/yard-0.9.44/lib/yard/templates/helpers/markup/rdoc_markdown.rb +23 -0
  240. data/yard-0.9.44/lib/yard/templates/helpers/markup/rdoc_markup.rb +112 -0
  241. data/yard-0.9.44/lib/yard/templates/helpers/markup_helper.rb +175 -0
  242. data/yard-0.9.44/lib/yard/templates/helpers/method_helper.rb +77 -0
  243. data/yard-0.9.44/lib/yard/templates/helpers/module_helper.rb +21 -0
  244. data/yard-0.9.44/lib/yard/templates/helpers/text_helper.rb +112 -0
  245. data/yard-0.9.44/lib/yard/templates/helpers/uml_helper.rb +47 -0
  246. data/yard-0.9.44/lib/yard/templates/section.rb +103 -0
  247. data/yard-0.9.44/lib/yard/templates/template.rb +420 -0
  248. data/yard-0.9.44/lib/yard/templates/template_options.rb +91 -0
  249. data/yard-0.9.44/lib/yard/verifier.rb +151 -0
  250. data/yard-0.9.44/lib/yard/version.rb +6 -0
  251. data/yard-0.9.44/lib/yard.rb +75 -0
  252. data/yard-0.9.44/po/ja.po +31108 -0
  253. data/yard-0.9.44/templates/default/class/dot/setup.rb +7 -0
  254. data/yard-0.9.44/templates/default/class/dot/superklass.erb +3 -0
  255. data/yard-0.9.44/templates/default/class/html/constructor_details.erb +8 -0
  256. data/yard-0.9.44/templates/default/class/html/setup.rb +2 -0
  257. data/yard-0.9.44/templates/default/class/html/subclasses.erb +4 -0
  258. data/yard-0.9.44/templates/default/class/setup.rb +36 -0
  259. data/yard-0.9.44/templates/default/class/text/setup.rb +12 -0
  260. data/yard-0.9.44/templates/default/class/text/subclasses.erb +5 -0
  261. data/yard-0.9.44/templates/default/constant/text/header.erb +11 -0
  262. data/yard-0.9.44/templates/default/constant/text/setup.rb +4 -0
  263. data/yard-0.9.44/templates/default/docstring/html/abstract.erb +4 -0
  264. data/yard-0.9.44/templates/default/docstring/html/deprecated.erb +1 -0
  265. data/yard-0.9.44/templates/default/docstring/html/index.erb +5 -0
  266. data/yard-0.9.44/templates/default/docstring/html/note.erb +6 -0
  267. data/yard-0.9.44/templates/default/docstring/html/private.erb +4 -0
  268. data/yard-0.9.44/templates/default/docstring/html/returns_void.erb +1 -0
  269. data/yard-0.9.44/templates/default/docstring/html/text.erb +1 -0
  270. data/yard-0.9.44/templates/default/docstring/html/todo.erb +6 -0
  271. data/yard-0.9.44/templates/default/docstring/setup.rb +52 -0
  272. data/yard-0.9.44/templates/default/docstring/text/abstract.erb +2 -0
  273. data/yard-0.9.44/templates/default/docstring/text/deprecated.erb +2 -0
  274. data/yard-0.9.44/templates/default/docstring/text/index.erb +2 -0
  275. data/yard-0.9.44/templates/default/docstring/text/note.erb +4 -0
  276. data/yard-0.9.44/templates/default/docstring/text/private.erb +2 -0
  277. data/yard-0.9.44/templates/default/docstring/text/returns_void.erb +1 -0
  278. data/yard-0.9.44/templates/default/docstring/text/text.erb +1 -0
  279. data/yard-0.9.44/templates/default/docstring/text/todo.erb +4 -0
  280. data/yard-0.9.44/templates/default/fulldoc/html/css/common.css +1 -0
  281. data/yard-0.9.44/templates/default/fulldoc/html/css/full_list.css +206 -0
  282. data/yard-0.9.44/templates/default/fulldoc/html/css/style.css +1089 -0
  283. data/yard-0.9.44/templates/default/fulldoc/html/frames.erb +22 -0
  284. data/yard-0.9.44/templates/default/fulldoc/html/full_list.erb +40 -0
  285. data/yard-0.9.44/templates/default/fulldoc/html/full_list_class.erb +2 -0
  286. data/yard-0.9.44/templates/default/fulldoc/html/full_list_file.erb +7 -0
  287. data/yard-0.9.44/templates/default/fulldoc/html/full_list_method.erb +10 -0
  288. data/yard-0.9.44/templates/default/fulldoc/html/js/app.js +801 -0
  289. data/yard-0.9.44/templates/default/fulldoc/html/js/full_list.js +334 -0
  290. data/yard-0.9.44/templates/default/fulldoc/html/js/jquery.js +4 -0
  291. data/yard-0.9.44/templates/default/fulldoc/html/setup.rb +249 -0
  292. data/yard-0.9.44/templates/default/layout/dot/header.erb +6 -0
  293. data/yard-0.9.44/templates/default/layout/dot/setup.rb +15 -0
  294. data/yard-0.9.44/templates/default/layout/html/breadcrumb.erb +11 -0
  295. data/yard-0.9.44/templates/default/layout/html/files.erb +11 -0
  296. data/yard-0.9.44/templates/default/layout/html/footer.erb +5 -0
  297. data/yard-0.9.44/templates/default/layout/html/headers.erb +15 -0
  298. data/yard-0.9.44/templates/default/layout/html/index.erb +2 -0
  299. data/yard-0.9.44/templates/default/layout/html/layout.erb +26 -0
  300. data/yard-0.9.44/templates/default/layout/html/listing.erb +4 -0
  301. data/yard-0.9.44/templates/default/layout/html/objects.erb +32 -0
  302. data/yard-0.9.44/templates/default/layout/html/script_setup.erb +4 -0
  303. data/yard-0.9.44/templates/default/layout/html/search.erb +13 -0
  304. data/yard-0.9.44/templates/default/layout/html/setup.rb +89 -0
  305. data/yard-0.9.44/templates/default/method/html/header.erb +17 -0
  306. data/yard-0.9.44/templates/default/method/setup.rb +4 -0
  307. data/yard-0.9.44/templates/default/method/text/header.erb +1 -0
  308. data/yard-0.9.44/templates/default/method_details/html/header.erb +3 -0
  309. data/yard-0.9.44/templates/default/method_details/html/method_signature.erb +25 -0
  310. data/yard-0.9.44/templates/default/method_details/html/source.erb +10 -0
  311. data/yard-0.9.44/templates/default/method_details/setup.rb +11 -0
  312. data/yard-0.9.44/templates/default/method_details/text/header.erb +10 -0
  313. data/yard-0.9.44/templates/default/method_details/text/method_signature.erb +12 -0
  314. data/yard-0.9.44/templates/default/method_details/text/setup.rb +11 -0
  315. data/yard-0.9.44/templates/default/module/dot/child.erb +1 -0
  316. data/yard-0.9.44/templates/default/module/dot/dependencies.erb +3 -0
  317. data/yard-0.9.44/templates/default/module/dot/header.erb +6 -0
  318. data/yard-0.9.44/templates/default/module/dot/info.erb +14 -0
  319. data/yard-0.9.44/templates/default/module/dot/setup.rb +15 -0
  320. data/yard-0.9.44/templates/default/module/html/attribute_details.erb +10 -0
  321. data/yard-0.9.44/templates/default/module/html/attribute_summary.erb +8 -0
  322. data/yard-0.9.44/templates/default/module/html/box_info.erb +43 -0
  323. data/yard-0.9.44/templates/default/module/html/children.erb +8 -0
  324. data/yard-0.9.44/templates/default/module/html/constant_summary.erb +17 -0
  325. data/yard-0.9.44/templates/default/module/html/defines.erb +3 -0
  326. data/yard-0.9.44/templates/default/module/html/header.erb +5 -0
  327. data/yard-0.9.44/templates/default/module/html/inherited_attributes.erb +14 -0
  328. data/yard-0.9.44/templates/default/module/html/inherited_constants.erb +8 -0
  329. data/yard-0.9.44/templates/default/module/html/inherited_methods.erb +20 -0
  330. data/yard-0.9.44/templates/default/module/html/item_summary.erb +40 -0
  331. data/yard-0.9.44/templates/default/module/html/method_details_list.erb +9 -0
  332. data/yard-0.9.44/templates/default/module/html/method_summary.erb +22 -0
  333. data/yard-0.9.44/templates/default/module/html/methodmissing.erb +12 -0
  334. data/yard-0.9.44/templates/default/module/html/pre_docstring.erb +1 -0
  335. data/yard-0.9.44/templates/default/module/setup.rb +187 -0
  336. data/yard-0.9.44/templates/default/module/text/children.erb +10 -0
  337. data/yard-0.9.44/templates/default/module/text/class_meths_list.erb +8 -0
  338. data/yard-0.9.44/templates/default/module/text/extends.erb +8 -0
  339. data/yard-0.9.44/templates/default/module/text/header.erb +7 -0
  340. data/yard-0.9.44/templates/default/module/text/includes.erb +8 -0
  341. data/yard-0.9.44/templates/default/module/text/instance_meths_list.erb +8 -0
  342. data/yard-0.9.44/templates/default/module/text/setup.rb +13 -0
  343. data/yard-0.9.44/templates/default/onefile/html/files.erb +5 -0
  344. data/yard-0.9.44/templates/default/onefile/html/headers.erb +8 -0
  345. data/yard-0.9.44/templates/default/onefile/html/layout.erb +16 -0
  346. data/yard-0.9.44/templates/default/onefile/html/readme.erb +3 -0
  347. data/yard-0.9.44/templates/default/onefile/html/setup.rb +62 -0
  348. data/yard-0.9.44/templates/default/root/dot/child.erb +3 -0
  349. data/yard-0.9.44/templates/default/root/dot/setup.rb +6 -0
  350. data/yard-0.9.44/templates/default/root/html/setup.rb +2 -0
  351. data/yard-0.9.44/templates/default/tags/html/example.erb +11 -0
  352. data/yard-0.9.44/templates/default/tags/html/index.erb +3 -0
  353. data/yard-0.9.44/templates/default/tags/html/option.erb +24 -0
  354. data/yard-0.9.44/templates/default/tags/html/overload.erb +14 -0
  355. data/yard-0.9.44/templates/default/tags/html/see.erb +8 -0
  356. data/yard-0.9.44/templates/default/tags/html/tag.erb +20 -0
  357. data/yard-0.9.44/templates/default/tags/setup.rb +57 -0
  358. data/yard-0.9.44/templates/default/tags/text/example.erb +12 -0
  359. data/yard-0.9.44/templates/default/tags/text/index.erb +1 -0
  360. data/yard-0.9.44/templates/default/tags/text/option.erb +20 -0
  361. data/yard-0.9.44/templates/default/tags/text/overload.erb +19 -0
  362. data/yard-0.9.44/templates/default/tags/text/see.erb +11 -0
  363. data/yard-0.9.44/templates/default/tags/text/tag.erb +13 -0
  364. data/yard-0.9.44/templates/guide/class/html/setup.rb +2 -0
  365. data/yard-0.9.44/templates/guide/docstring/html/setup.rb +2 -0
  366. data/yard-0.9.44/templates/guide/fulldoc/html/css/style.css +358 -0
  367. data/yard-0.9.44/templates/guide/fulldoc/html/js/app.js +61 -0
  368. data/yard-0.9.44/templates/guide/fulldoc/html/setup.rb +74 -0
  369. data/yard-0.9.44/templates/guide/layout/html/layout.erb +78 -0
  370. data/yard-0.9.44/templates/guide/layout/html/setup.rb +25 -0
  371. data/yard-0.9.44/templates/guide/method/html/header.erb +18 -0
  372. data/yard-0.9.44/templates/guide/method/html/setup.rb +22 -0
  373. data/yard-0.9.44/templates/guide/module/html/header.erb +7 -0
  374. data/yard-0.9.44/templates/guide/module/html/method_list.erb +5 -0
  375. data/yard-0.9.44/templates/guide/module/html/setup.rb +27 -0
  376. data/yard-0.9.44/templates/guide/onefile/html/files.erb +4 -0
  377. data/yard-0.9.44/templates/guide/onefile/html/setup.rb +6 -0
  378. data/yard-0.9.44/templates/guide/onefile/html/toc.erb +3 -0
  379. data/yard-0.9.44/templates/guide/tags/html/setup.rb +9 -0
  380. metadata +419 -0
@@ -0,0 +1,1297 @@
1
+ # @title What's New?
2
+
3
+ # What's New in 0.9.x?
4
+
5
+ ## Support for Ruby Signature Files (.rbs) (0.9.40)
6
+
7
+ YARD now supports parsing Ruby signature files (.rbs) with full docstring support. This means you can write your documentation in `.rbs` files and have it show up in generated documentation, and use `.rbs` files alongside `.rb` sources to supplement type and API information.
8
+
9
+ ## New built-in Markdown renderer (0.9.40)
10
+
11
+ YARD now ships with a built-in Markdown renderer (`YARD::Templates::Helpers::Markup::HybridMarkdown`)
12
+ that requires **no external gems**. It supports a practical subset of GitHub Flavored Markdown (GFM)
13
+ as well as common RDoc markup forms, including:
14
+
15
+ - Headings (`#`, `=`)
16
+ - Fenced code blocks (`` ``` `` and `~~~`) as well as RDoc formatted `+text+` blocks.
17
+ - Tables, blockquotes, and thematic breaks
18
+ - Ordered and unordered lists (including RDoc-style)
19
+ - Inline emphasis, code, links, and images
20
+ - HTML passthrough blocks
21
+
22
+ This renderer is the **default** for both the `rdoc` and `markdown` markup types—no gem
23
+ installation required. If an optional provider gem (e.g. `redcarpet`, `kramdown`,
24
+ `commonmarker`) is installed and selected, YARD will use it instead for extra features such
25
+ as custom extensions or stricter spec compliance.
26
+
27
+ ## `#-` comment block separators (0.9.40)
28
+
29
+ YARD now recognizes a trailing `#-` line as a separator between comment
30
+ blocks. This is useful when you want to keep a file header comment at the top
31
+ of a Ruby file without having that header attach itself to the first class,
32
+ module or method in the file.
33
+
34
+ For example:
35
+
36
+ # Copyright (c) Example Corp
37
+ # This file defines support code shared by the client.
38
+ #-
39
+
40
+ class Client
41
+ end
42
+
43
+ In the example above, the file header stays disconnected from `Client`.
44
+ Note that `# -` does **not** act as a separator; only an attached `#-`
45
+ line has this behavior.
46
+
47
+ ## Ruby 4.x support (0.9.39)
48
+
49
+ Added support for Ruby 4.x along with new syntaxes.
50
+
51
+ ## Other changes
52
+
53
+ See the [CHANGELOG](CHANGELOG.md) for a full list of changes in 0.9.x.
54
+
55
+ # What's New in 0.8.x?
56
+
57
+ 1. **Directives (new behavioural tag syntax)** (0.8.0)
58
+ 2. **Added `--embed-mixin(s)` to embed mixins into class docs** (0.8.0)
59
+ 3. **Internationalization (I18n) support for translating docs** (0.8.0)
60
+ 4. **New C parser / handlers architecture** (0.8.0)
61
+ 5. **YARD will now warn if `@param` name not in method params** (0.8.0)
62
+ 6. **Added support for `module_function` calls in Ruby code** (0.8.0)
63
+ 7. **Greatly improved tag documentation using custom template** (0.8.0)
64
+ 8. **Tags can now contain '.' for namespacing** (0.8.0)
65
+ 9. **Added "frames" links for non-framed pages for better nav** (0.8.0)
66
+ 10. **Added Gemfile support to YARD server for local gem sets** (0.8.0)
67
+ 11. **Server now displays README on index route like static docs** (0.8.0)
68
+ 12. **Added line numbers to `yard stats --list-undoc --compact`** (0.8.0)
69
+ 13. **Single object db now default (multi-object db unsupported)** (0.8.0)
70
+ 14. **Added `--api` tag to generate documentation for API sets** (0.8.1)
71
+ 15. **Added `--non-transitive-tag` to disable transitive tag** (0.8.3)
72
+ 16. **Added `-B/--bind` to bind to a port in yard server** (0.8.4)
73
+ 17. **Added `asciidoc` markup type support** (0.8.6)
74
+ 18. **Added `yard markups` command to list available markup types** (0.8.6)
75
+ 19. **Added `yard display` command to display formatted objects** (0.8.6)
76
+ 20. **Added `--layout` to `yard display` command** (0.8.6.1)
77
+ 21. **Added `stats_options` for the rake task** (0.8.7.6)
78
+
79
+ ## Directives (new behavioural tag syntax) (0.8.0)
80
+
81
+ <p class="note">
82
+ The tags {tag:!macro}, {tag:!method}, {tag:!attribute}, {tag:!group},
83
+ {tag:!endgroup}, {tag:!scope} and {tag:!visibility} have been changed
84
+ from meta-data tags to directives. This means they should now be called
85
+ with the "@!" prefix instead of "@". Note however that for <strong>
86
+ backward compatibility</strong>, the old "@macro", "@method", etc.,
87
+ syntax for all of these tags will still work and is supported.
88
+ </p>
89
+
90
+ <p class="note">
91
+ Some <strong>backwards incompatible</strong> changes were made to {tag:!macro} syntax.
92
+ Please read this section carefully if you are using this tag.
93
+ </p>
94
+
95
+ YARD 0.8.0 adds a new tag syntax called "directives" using the `@!`
96
+ prefix. These directive tags can be used to modify parser state while
97
+ processing objects, or even create new objects on the fly. A plugin
98
+ API is available similar to tags, and directives should be registered
99
+ in the {YARD::Tags::Library} class using {YARD::Tags::Library.define_directive}.
100
+
101
+ To use a directive, simply call it the same way as any tag. Tag syntax
102
+ is documented in {file:docs/Tags.md}.
103
+
104
+ ### Notable features of directives
105
+
106
+ #### Directives do not need to be attached to object docstrings
107
+
108
+ Unlike meta-data tags which apply to created objects, directives
109
+ do not need to be attached to an object in order to be used. This
110
+ means you can have free-standing comments with directives, such as:
111
+
112
+ # @macro mymacro
113
+ # A new macro, not attached to any docstring
114
+
115
+ # ...other Ruby code here...
116
+
117
+ # Using the macro:
118
+ # @macro mymacro
119
+ def mymethod; end
120
+
121
+ You can do the same to define methods and attributes, as discussed
122
+ below.
123
+
124
+ #### `@!method` and `@!attribute` directives improved
125
+
126
+ The method and attribute directives can now be used to create multiple
127
+ objects in a single docstring. Previously a `@method` or `@attribute`
128
+ tag would only create one method per docstring. In 0.8.0, you could
129
+ attach multiple methods to the same block of Ruby source, such as:
130
+
131
+ # @!method foo(a, b, c)
132
+ # @!method bar(x, y, z)
133
+ # Docstring for code
134
+ some_ruby_source
135
+
136
+ The above creates #foo and #bar and the source listing for both will
137
+ be `some_ruby_source` with "Docstring for code" as the docstring.
138
+
139
+ The attribute directive can take advantage of this functionality as well.
140
+ Note that these directives also do not need to be attached to a line of
141
+ code to be recognized; they can be in free-standing comments if the
142
+ methods are defined dynamically and not associated with any code.
143
+
144
+ #### New `@!parse` directive to parse Ruby code
145
+
146
+ A new {tag:!parse} directive was added that allows a developer to have
147
+ YARD parse code that might not necessarily be parsable in its original
148
+ form. This is useful when using `instance_eval` and other dynamic
149
+ meta-programming techniques to define methods or perform functionality.
150
+ For instance, a common case of the "self.included" callback in module
151
+ to extend a module on a class might be in the form:
152
+
153
+ def self.included(mod)
154
+ mod.extend(self)
155
+ end
156
+
157
+ Unfortunately, this does not get picked up by YARD, but on the original
158
+ class, we can add:
159
+
160
+ class MyClass
161
+ # @!parse extend TheDynamicModule
162
+ include TheDynamicModule
163
+ end
164
+
165
+ YARD will then parse the code `extend TheDynamicModule` as if
166
+ it were in the source file.
167
+
168
+ You can also use this technique to register regular methods as
169
+ attributes, if you did not define them with `attr_*` methods:
170
+
171
+ def foo; @foo end
172
+ def foo=(v) @foo = v end
173
+
174
+ # Register them as methods:
175
+ # @!parse attr_accessor :foo
176
+
177
+ ### Backward incompatible changes to `@!macro` directive
178
+
179
+ Unfortunately, in order to create the new directives architecture,
180
+ some previously supported syntax in `@macro` tags are no longer supported.
181
+ Specifically, macros can no longer expand text on an entire docstring.
182
+ Instead, macros only expand the data that is indented inside of the tag
183
+ text.
184
+
185
+ This syntax is **no longer supported**:
186
+
187
+ # @macro mymacro
188
+ # Expanding text $1 $2 $3
189
+ property :a, :b, :c
190
+
191
+ In 0.7.0 to 0.7.5, the above would have created a method with the docstring
192
+ "Expanding text a b c". This will not work in 0.8.0. Instead, you must
193
+ indent all the macro expansion data so that it is part of the `@macro`
194
+ tag as follows:
195
+
196
+ # @!macro mymacro
197
+ # Expanding text $1 $2 $3
198
+ property :a, :b, :c
199
+
200
+ Note that we also use the recommended `@!macro` syntax, though `@macro`
201
+ is still supported.
202
+
203
+ ## Added `--embed-mixin(s)` to embed mixins into class docs (0.8.0)
204
+
205
+ Methods from mixins can now be embedded directly into the documentation
206
+ output for a class by using `--embed-mixin ModuleName`, or `--embed-mixins`
207
+ for all mixins. This enables a documentation writer to refactor methods
208
+ into modules without worrying about them showing up in separate files
209
+ in generated documentation. When mixin methods are embedded, they
210
+ show up in both the original module page and the pages of the classes
211
+ they are mixed into. A note is added to the method signature telling the
212
+ user where the method comes from.
213
+
214
+ The `--embed-mixin` command-line option can also take wildcard values
215
+ in order to match specific namespaces. For instance, you can embed
216
+ only mixins inside of a "Foo::Bar" namespace by doing:
217
+
218
+ !!!sh
219
+ $ yard doc --embed-mixin "Foo::Bar::*"
220
+
221
+ ## Internationalization (I18n) support for translating docs
222
+
223
+ YARD now ships with the beginnings of internationalization support
224
+ for translating documentation into multiple languages. The
225
+ `yard i18n` command now allows you to generate ".pot" and ultimately
226
+ ".po" files for translation with [gettext](https://www.gnu.org/software/gettext).
227
+
228
+ Note that this tool is a small step in the larger transition for
229
+ proper I18n support in YARD. We still have to add proper gettext
230
+ support to our templates for proper generation in multiple languages,
231
+ but this tool allows you to get started in translating your
232
+ documents. Improved I18n support will come throughout the 0.8.x series.
233
+
234
+ ## New C parser / handlers architecture (0.8.0)
235
+
236
+ The C parser was completely rewritten to take advantage of YARD's
237
+ parser and handler architecture. This means more YARD will be more robust
238
+ when parsing failures occur, tags and directives will now work consistently
239
+ across Ruby and CRuby files ({tag:!group} will now work, for instance),
240
+ and developers can now write custom handlers that target CRuby source files.
241
+
242
+ ## YARD will now warn if `@param` name not in method params (0.8.0)
243
+
244
+ YARD will now give you a warning if you use a `@param` tag in your
245
+ source but give an invalid parameter name. This should catch a lot of
246
+ common documentation errors and help keep your documentation consistent.
247
+
248
+ ## Added support for `module_function` calls in Ruby code (0.8.0)
249
+
250
+ The `module_function` command in Ruby is now supported in Ruby files.
251
+ It defines two separate methods, one class and one instance method,
252
+ both having the exact same docstring, and marks the instance method
253
+ as private.
254
+
255
+ ## Greatly improved tag documentation using custom template (0.8.0)
256
+
257
+ We have completely revamped the {docs/Tags.md} to include documentation
258
+ for each meta-data tag and directive with at least one useful example
259
+ for each one. This was done using template customization and extension
260
+ available within YARD.
261
+
262
+ ## Tags can now contain '.' for namespacing (0.8.0)
263
+
264
+ Prior to 0.8.0, tags could only contain alphanumeric characters and
265
+ underscore. YARD now allows the '.' character in tag names, and it
266
+ is now recommended for namespacing project-specific custom tags.
267
+ YARD has its own set of custom tags that are namespaced in this
268
+ way (using the "yard.tagname" namespace). The namespace recommendation
269
+ is to use "projectname.tagname", or "projectname.component.tagname".
270
+
271
+ ## Added "frames" links for non-framed pages for better nav (0.8.0)
272
+
273
+ Frames navigation has always had a "(no frames)" link to get rid
274
+ of the frameset. YARD 0.8.0 introduces a "(frames)" link on non-framed
275
+ pages to reverse this, allowing you to navigate between framed and
276
+ frameless pages seamlessly.
277
+
278
+ ## Added Gemfile support to YARD server for local gem sets (0.8.0)
279
+
280
+ The `yard server` command now supports `--gemfile` to serve gems
281
+ from a Gemfile.lock, instead of all system-wide gems.
282
+
283
+ ## Server now displays README on index route like static docs (0.8.0)
284
+
285
+ The `yard server` command will now behave like static docs regarding
286
+ the index action for a project, listing the README file if present
287
+ before displaying the alphabetic index. Note that the route for
288
+ the alphabetic index page has now moved to the explicit '/index' action.
289
+
290
+ ## Added line numbers to `yard stats --list-undoc --compact` (0.8.0)
291
+
292
+ Line numbers are now listed in the compact listing of undocumented objects
293
+ so that they can be more easily located in the files.
294
+
295
+ ## Single object db now default (multi-object db unsupported) (0.8.0)
296
+
297
+ YARD previously would split the .yardoc db into multiple marshal files
298
+ for load-time performance reasons if it grew past a specific number of
299
+ objects. This check is now disabled, and YARD will never automatically
300
+ switch to a multi-object DB. YARD will now always use the single object
301
+ db unless explicitly set with `--no-single-db`. If YARD is taking a
302
+ long time to load your .yardoc database, you can try using this
303
+ option to split your database into multiple files, but note that this
304
+ can cause problems with certain codebases (specifically, if you
305
+ have class methods using the same name as a module/class).
306
+
307
+ ## Added `--api` tag to generate documentation for API sets (0.8.1)
308
+
309
+ You can now use `yardoc --api APINAME` to generate documentation only
310
+ for objects with the `@api APINAME` tag (or any parent namespace objects,
311
+ since this tag is transitive). Multiple `--api` switches may be used to
312
+ generate documentation for multiple APIs together. The following generates
313
+ documentation for both the "public" and "developer" APIs, also including
314
+ any objects with undefined API (via `--no-api`):
315
+
316
+ $ yard doc --api public --api developer --no-api
317
+
318
+ Note that if you use `--api`, you must ensure that you also add `@api`
319
+ tags to your namespace objects (modules and classes), not just your methods.
320
+ If you do not want to do this, you can also include all objects with *no*
321
+ `@api` tag by using `--no-api` as shown above.
322
+
323
+ Remember that applying an `@api` tag to a class or module will apply it
324
+ to all children that do not have this tag already defined, so you can
325
+ declare an entire class public by applying it to the class itself. Note
326
+ also that these tags can be overridden by child elements if the tag is
327
+ re-applied to the individual object.
328
+
329
+ This feature is a simplified version of the more powerful `--query`
330
+ switch. The query to display the same API documentation as the
331
+ above example would be:
332
+
333
+ $ yard doc --query '!@api || @api.text =~ /^(public|private)$/'
334
+
335
+ But note that `--query` does not work when YARD is in "safe mode"
336
+ due to security concerns, whereas `--api` works in either mode.
337
+ This enables `--api` to function on remote documentation sites like
338
+ [rubydoc.info](https://rubydoc.info).
339
+
340
+ ## Added `--non-transitive-tag` to disable transitive tag (0.8.3)
341
+
342
+ You can now use `--non-transitive-tag` to disable transitivity on
343
+ tags that are defined as transitive by default. For instance, in
344
+ some cases you might not want the @api tag to apply to all methods
345
+ when you define it on a class. Only the class itself has a specific
346
+ @api tag. To do this, you can mark @api as non-transitive with:
347
+
348
+ $ yard doc --non-transitive-tag api --api some_api
349
+
350
+ Which will avoid classifying treating @api as a transitive tag
351
+ when parsing modules and classes.
352
+
353
+ ## Added `-B/--bind` to bind to a port in yard server (0.8.4)
354
+
355
+ You can now bind the `yard server` command to a given local port
356
+ with `yard server -B PORT` or `yard server --bind PORT`.
357
+
358
+ ## Added `asciidoc` markup type support (0.8.6)
359
+
360
+ Support for the AsciiDoc markup type is now introduced using the `asciidoc`
361
+ markup type (`yard doc -m asciidoc`). Requires the
362
+ [asciidoctor](https://rubygems.org/gems/asciidoctor) RubyGem library to be
363
+ installed before running YARD.
364
+
365
+ ## Added `yard markups` command to list available markup types (0.8.6)
366
+
367
+ You can now list all available markup types and their respective providers by
368
+ typing `yard markups`. This list also includes the file extensions used to
369
+ auto-identify markup types for extra files and READMEs. To use a markup in
370
+ the list, call `yard doc` with `-m MARKUP_TYPE`. To select a specific markup
371
+ provider library, pass the `-M PROVIDER_NAME` option.
372
+
373
+ ## Added `yard display` command to display formatted objects (0.8.6)
374
+
375
+ <p class="note">This feature requires the .yardoc registry to have already been
376
+ generated. To generate the registry, run <code>yard doc -n</code>.
377
+ </p>
378
+
379
+ You can now display a single object (or a list of objects) in the YARD registry
380
+ using the `yard display OBJECT ...` command. For example, to display the
381
+ `YARD::CodeObjects` module as text (the way it is displayed in `yri`), type:
382
+
383
+ $ yard display YARD::CodeObjects
384
+
385
+ You can also format individual objects as HTML. For example, you can format
386
+ the above object as HTML and pipe the contents into a file readable by a
387
+ web browser:
388
+
389
+ $ yard display -f html YARD::CodeObjects > codeobjects.html
390
+
391
+ Custom templating options from `yard doc` can also be used, see
392
+ `yard display --help` for more options.
393
+
394
+ ## Added `--layout` to `yard display` command (0.8.6.1)
395
+
396
+ The `yard display` command now accepts `--layout` to wrap content in a layout
397
+ template. Currently the `layout` and `onefile` layout templates are supported,
398
+ though any template can be used. If no parameter is specified, the layout will
399
+ default to the `layout` template. Example usage:
400
+
401
+ $ yard display --layout onefile -f html YARD::CodeObjects > codeobjects.html
402
+
403
+ The above generates a `codeobjects.html` file that is self-contained with
404
+ CSS stylesheets and JavaScript code. This is similar to calling
405
+ `yard doc --one-file` with only the YARD::CodeObjects object in the registry.
406
+
407
+ Note that even though this uses the onefile template, the README file will not
408
+ be auto-included the way it is with the `yard doc` command. To include the
409
+ README text at the top of the onefile template, pass the --readme switch:
410
+
411
+ $ yard display --layout onefile -f html --readme README.md OBJECT > out.html
412
+
413
+ # What's New in 0.7.x?
414
+
415
+ 1. **Macro support and detection of DSL methods** (0.7.0)
416
+ 2. **Inherited attributes now show in HTML output** (0.7.0)
417
+ 3. **The 'app' directory is now parsed by default** (0.7.0)
418
+ 4. **Added support for metadata (@title, @markup) in extra files/readmes** (0.7.0)
419
+ 5. **Added `yard list` command (alias for `yardoc --list`)** (0.7.0)
420
+ 6. **Added Git support in `yard diff`** (0.7.0)
421
+ 7. **Added `{include:file:FILENAME}` syntax** (0.7.0)
422
+ 8. **Added `{render:OBJECT}` syntax to embed object docs in extra files** (0.7.0)
423
+ 9. **Added improved templates API for custom CSS/JS/menus** (0.7.0)
424
+ 10. **Added Ruby markup type (`-m ruby`)** (0.7.0)
425
+ 11. **Added state tracking variables to Parser/Handler architecture** (0.7.0)
426
+ 12. **Added before/after callbacks to SourceParser** (0.7.0)
427
+ 13. **Can now use `--yardopts FILE` to specify a custom yardopts file** (0.7.0)
428
+ 14. **Added new `-t guide` template for guide based docs** (0.7.0)
429
+ 15. **Github Flavoured Markdown now works out-of-box** (0.7.4)
430
+ 16. **Added `-m textile_strict` and `-m pre` markup types** (0.7.4)
431
+ 17. **Reorganized markup types 'text' and 'none'** (0.7.4)
432
+ 18. **Add support for `rb_define_alias`** (0.7.4)
433
+
434
+ ## Macro support and detection of DSL methods (0.7.0)
435
+
436
+ YARD will now automatically detect class level method calls, similar to the
437
+ way it knows what an `attr_accessor` is. By simply adding documentation to
438
+ your class level declarations, YARD can automatically detect them as methods
439
+ or attributes in your class. Consider DataMapper's "property" declaration:
440
+
441
+ class Post
442
+ # @attribute
443
+ # @return [String] the title of the post
444
+ property :title, String
445
+ end
446
+
447
+ The above declaration would be created as the `Post#title`. The optional
448
+ `@attribute` tag tells YARD that the property is an "attribute", and not just
449
+ a regular method.
450
+
451
+ In addition to basic DSL method detection, YARD also supports macros to create
452
+ docstrings that can be copies to other objects; these macros can also be
453
+ "attached" to class level methods to create implicit documentation for macros.
454
+
455
+ Macros and DSL method detection are discussed in much more detail in the
456
+ {file:docs/GettingStarted.md}, so you should read about them there if you're
457
+ interested in this feature.
458
+
459
+ ## Inherited attributes now show in HTML output (0.7.0)
460
+
461
+ Inherited attributes will now show up in HTML documentation using the default
462
+ template in the same manner that inherited methods do.
463
+
464
+ ## The 'app' directory is now parsed by default (0.7.0)
465
+
466
+ YARD tries to follow the "It Just Works" attitude in writing developer tools,
467
+ and therefore has added `app/**/*.rb` to the default list of globs that it
468
+ searches for code in. You no longer need to create a `.yardopts` just to
469
+ list your app directory when documenting your code on rubydoc.info.
470
+ We should have done this a while ago! And don't worry, YARD still checks
471
+ lib and ext by default, too.
472
+
473
+ ## Added support for metadata (@title, @markup) in extra files/readmes (0.7.0)
474
+
475
+ Extra files (READMEs, ChangeLogs, LICENSE files, and other guides) now support
476
+ metadata tags, just like docstrings in code comments. By adding @tag values
477
+ to the top of a file (no whitespace preceding it) inside of a `# comment` line,
478
+ YARD will detect and parse these tags and store it for later usage.
479
+
480
+ Tags can contain arbitrary data as well as arbitrary tag names, however the
481
+ tag names @title and @markup are reserved to specify the document title and
482
+ markup format respectively. The title will be used in the file list menu,
483
+ index page, as well as any linking of the file via the `{file:Filename}`
484
+ syntax. An example of a document with metadata would be:
485
+
486
+ # @title The Best Project Ever!
487
+ # @markup rdoc
488
+ # @author Foo Bar (custom tag, does not display in templates)
489
+
490
+ = This Project Rules
491
+
492
+ == Contents
493
+
494
+ ...
495
+
496
+ Note that previous versions of YARD recommended specifying the markup of an
497
+ extra file with the `#!markup` shebang, but the `@markup` metadata tag is now
498
+ the "best practice" for specifying the markup format of an extra file.
499
+
500
+ ## Added `yard list` command (alias for `yardoc --list`) (0.7.0)
501
+
502
+ The `yardoc --list` command is used to list objects that are parsed from
503
+ a codebase. This can be used to grep methods/classes in a codebase from the
504
+ command line. `yard list` now calls `yardoc --list` as a convenience command.
505
+
506
+ Note that the `yardoc --list` command may eventually be replaced by a more
507
+ feature-filled `yard list` command, so `yard list` should be used instead of
508
+ `yardoc --list` when possible.
509
+
510
+ ## Added Git support in `yard diff` (0.7.0)
511
+
512
+ The `yard diff` command can now perform object diffing on git repositories.
513
+ Provide the `--git` switch to `yard diff` with 2 commit/branches like so:
514
+
515
+ $ yard diff --git HEAD~5 HEAD
516
+ Added objects:
517
+
518
+ YARD::Parser::SourceParser#contents
519
+ YARD::Parser::SourceParser#globals
520
+ ...
521
+
522
+ ## Added `{include:file:FILENAME}` syntax (0.7.0)
523
+
524
+ You can now use the `{include:file:FILENAME}` syntax to embed the contents
525
+ of an extra file marked up in its markup format. This syntax supports embedding
526
+ Ruby source files and performing syntax highlighting on the code.
527
+
528
+ ## Added `{render:OBJECT}` syntax to embed object docs in extra files (0.7.0)
529
+
530
+ You can now use the `{render:Object}` syntax to embed the documentation
531
+ rendering of an entire object (method, class, module) inside of an extra file.
532
+ This is useful when writing non-API based guides that might require listing
533
+ a few helper methods or classes. The {file:docs/GettingStarted.md} discussed
534
+ this syntax in more detail (with example usage).
535
+
536
+ ## Added improved templates API for custom CSS/JS/menus (0.7.0)
537
+
538
+ Plugin & template developers can now more easily insert custom stylesheet
539
+ or JavaScript files in their customized templates, thanks to an abstraction
540
+ of the template API. This is documented in the {docs/Templates.md} document.
541
+ In addition to custom CSS/JS, developers can also create custom menu tabs
542
+ in both the framed and non framed version of the default theme.
543
+
544
+ ## Added Ruby markup type (`-m ruby`) (0.7.0)
545
+
546
+ The Ruby markup type (`-m ruby`) will now use syntax highlighting for all
547
+ formatting. This is probably not useful as a global switch, but can be used
548
+ on individual extra files using the metadata markup specification discussed
549
+ above.
550
+
551
+ ## Added state tracking variables to Parser/Handler architecture (0.7.0)
552
+
553
+ The parser and handler architecture now contain state variables
554
+ {YARD::Handlers::Base#extra_state} and {YARD::Handlers::Processor#globals}
555
+ to share data across handlers and the entire processing phase. `#extra_state`
556
+ provided a place to store per-file data, while `#globals` gives the developer
557
+ access to inter-file state when parsing multiple files at once.
558
+
559
+ ## Added before/after callbacks to SourceParser (0.7.0)
560
+
561
+ The {YARD::Parser::SourceParser} class can now register callbacks to execute
562
+ code before and after parsing of file globs, as well as before and after
563
+ parsing of individual files. This allows plugin developers to perform
564
+ setup/teardown (and set global state or update the {YARD::Registry}).
565
+
566
+ See the documentation for the following methods:
567
+
568
+ * {YARD::Parser::SourceParser.before_parse_list}
569
+ * {YARD::Parser::SourceParser.after_parse_list}
570
+ * {YARD::Parser::SourceParser.before_parse_file}
571
+ * {YARD::Parser::SourceParser.after_parse_file}
572
+
573
+ ## Can now use `--yardopts FILE` to specify a custom yardopts file (0.7.0)
574
+
575
+ The `yardoc` command now supports `--yardopts FILE` to specify custom .yardopts
576
+ options files. This is useful if you have multiple documentation sets, such
577
+ as a guide documentation set and an API documentation set.
578
+
579
+ ## Added new `-t guide` template for guide based docs (0.7.0)
580
+
581
+ You can now write guide style documentation using a new 'guide' template that
582
+ only generates documentation for extra files. You would use it in the form:
583
+
584
+ yardoc -t guide - README GettingStarted FAQ TroubleShooting LICENSE
585
+
586
+ This creates the sections for the readme, a getting started, frequently asked
587
+ questions, trouble shooting and license page.
588
+
589
+ If you need to refer to class / method documentation, you can embed API documentation
590
+ using the `{render:Object}` tag discussed above.
591
+
592
+ ## Github Flavoured Markdown now works out-of-box (0.7.4)
593
+
594
+ Due to the growing popularity of Github-Flavoured-Markdown (GFM), YARD now uses
595
+ the Redcarpet library as the default Markdown formatting library with GFM fenced
596
+ code blocks enabled. This means that you can use fenced code blocks inside of
597
+ Markdown files with redcarpet installed without any extra code. Previously, users
598
+ who wanted GFM in their Markdown would have to specify `-m markdown -M redcarpet`,
599
+ but this is now the default behaviour for YARD.
600
+
601
+ Note that you can still specify language types in code blocks without GFM in YARD
602
+ by using the "!!!lang" prefix syntax. For example (plain means no markup):
603
+
604
+ !!!plain
605
+ !!!plain
606
+ Some code
607
+ block here.
608
+
609
+ The GFM version would be:
610
+
611
+ !!!plain
612
+ ```plain
613
+ Some code
614
+ block here.
615
+ ```
616
+
617
+ ## Added `-m textile_strict` and `-m pre` markup types (0.7.4)
618
+
619
+ A new "textile_strict" markup type was added which behaves exactly like "textile"
620
+ except it enables hard breaks, so newlines behave as line breaks in the HTML
621
+ (using `<br>` tags). This option is added for users who want the classic textile
622
+ behaviour.
623
+
624
+ ## Reorganized markup types 'text' and 'none' (0.7.4)
625
+
626
+ Due to the new pre markup type, the behaviour for text and none were slightly
627
+ reorganized to be more intuitive. The following behaviours now represent these
628
+ markup types:
629
+
630
+ * pre: Used to wrap text inside `<pre>` tags
631
+ * text: No formatting except for hard breaks (`<br>`) on newlines
632
+ * none: No formatting at all.
633
+
634
+ In all cases, HTML is escaped from input. If you want no HTML escaping, use the
635
+ html markup type.
636
+
637
+ ## Add support for `rb_define_alias` (0.7.4)
638
+
639
+ CRuby code can now make use of the `rb_define_alias` function. Documentation
640
+ for aliases is not supported, however.
641
+
642
+ # What's New in 0.6.x?
643
+
644
+ 1. **Local documentation server for RubyGems or projects (`yard server`)** (0.6.0)
645
+ 2. **Groups support for method listing** (0.6.0)
646
+ 3. **Single file template (`--one-file`) support** (0.6.0)
647
+ 4. **`yard` CLI executable with pluggable commands** (0.6.0)
648
+ 5. **`yard diff` command to object-diff two versions of a project** (0.6.0)
649
+ 6. **Added `--asset` option to `yardoc`** (0.6.0)
650
+ 7. **New template API** (0.6.0)
651
+ 8. **HTML template now adds inline Table of Contents for extra files pages** (0.6.0)
652
+ 9. **Removed `--incremental` in favour of `--use-cache`** (0.6.0)
653
+ 10. **Ad-hoc tag registration via `yardoc` CLI (`--tag`, etc.)** (0.6.0)
654
+ 11. **Added `--transitive-tags` to register transitive tags** (0.6.0)
655
+ 12. **`yardoc` now displays RDoc-like statistics (`--no-stats` to hide)** (0.6.0)
656
+ 13. **`yri` now works on constants** (0.6.0)
657
+ 14. **Plugins are no longer auto-loaded (added `--plugin` switch)** (0.6.2)
658
+ 15. **Added `YARD::Config` API and `~/.yard/config` configuration file** (0.6.2)
659
+ 16. **Added `yard config` command to view/edit configuration** (0.6.2)
660
+ 17. **Added `yard server -t` template path switch** (0.6.2)
661
+ 18. **Added `YARD::Server.register_static_path` for static server assets** (0.6.2)
662
+ 19. **YARD::Registry is now thread local** (0.6.5)
663
+ 20. **Support for ripper gem in Ruby 1.8.7** (0.6.5)
664
+
665
+ ## Local documentation server for RubyGems or projects (`yard server`) (0.6.0)
666
+
667
+ The new `yard server` command spawns a documentation server that can serve
668
+ either documentation for a local project or installed RubyGems. The server
669
+ will host (by default) on http://localhost:8808.
670
+
671
+ To serve documentation for the active project (in the current directory):
672
+
673
+ $ yard server
674
+
675
+ The server can also run in "incremental" mode for local projects. In this
676
+ situation, any modified sources will immediately be updated at each request,
677
+ ensuring that the server always serve the code exactly as it is on disk.
678
+ Documenting your code in this fashion essentially gives you an efficient a
679
+ live preview without running a separate command everytime you make a change.
680
+ To serve documentation for the active project in incremental mode:
681
+
682
+ $ yard server --reload
683
+
684
+ <span class="note">Note that in incremental mode, objects or method groupings
685
+ cannot be removed. If you have removed objects or modified groupings, you
686
+ will need to flush the cache by deleting `.yardoc` and (optionally)
687
+ restarting the server.</span>
688
+
689
+ The documentation server can also serve documentation for all installed gems
690
+ on your system, similar to `gem server`, but using YARD's functionality and
691
+ templates. To serve documentation for installed gems:
692
+
693
+ $ yard server --gems
694
+
695
+ <span class="note">Documentation for the gem need not be previously generated
696
+ at install-time. If documentation for the gem has not been generated, YARD
697
+ will do this for you on-the-fly. It is therefore possible to speed up your
698
+ gem installs by using `gem install GEMNAME --no-rdoc` without repercussion.
699
+ You can also add this switch to your `~/.gemrc` file so that you don't need
700
+ to re-type it each time. See [this link](https://stackoverflow.com/questions/1789376/how-do-i-make-no-ri-no-rdoc-the-default-for-gem-install)
701
+ for exact instructions.</span>
702
+
703
+ ## Groups support for method listing (0.6.0)
704
+
705
+ You can now organize methods in a class/module into logical separated groups.
706
+ These groups apply lexically and are listed in the order they are defined.
707
+ For instance, to define a group:
708
+
709
+ # @group Rendering an Object
710
+
711
+ # Documentation here
712
+ def foo; end
713
+
714
+ # Extra documentation...
715
+ def bar; end
716
+
717
+ # @group Another Group
718
+
719
+ def aaa; end
720
+
721
+ <span class="note">Note that these `@group` and `@endgroup` declarations are
722
+ not "tags" and should always be separated with at least 1 line of whitespace
723
+ from any other documentation or code.</span>
724
+
725
+ In the above example, "Rendering an Object" will be listed with "foo" and
726
+ "bar" above "Another Group", even though "aaa" comes before the two other
727
+ methods, alphabetically. To end a group, use `@endgroup`. It is not necessary
728
+ to end a group to start a new one, only if there is an object following the
729
+ group that should not belong in any group.
730
+
731
+ # @group Group 1
732
+
733
+ def foo; end
734
+
735
+ # @endgroup
736
+
737
+ # This method should not be listed in any group
738
+ def bar; end
739
+
740
+ ## Single file template (`--one-file`) support (0.6.0)
741
+
742
+ `yardoc` now has the `--one-file` option to generate a single-file template
743
+ for small scripts and libraries. In this case, any comments at the top of
744
+ the script file will be recognized as a README.
745
+
746
+ ## `yard` CLI executable with pluggable commands (0.6.0)
747
+
748
+ <span class="note">The `yardoc` and `yri` commands are not deprecated and can
749
+ continue to be used. They are shortcuts for `yard doc` and `yard ri`
750
+ respectively. However, `yard-graph` has been removed.</span>
751
+
752
+ YARD now has a `yard` executable which combines all pre-existing and new
753
+ commands into a single pluggable command that is both easier to remember and
754
+ access. To get a list of commands, type `yard --help`.
755
+
756
+ If you are a plugin developer, you can create your own `yard` command by first
757
+ subclassing the {YARD::CLI::Command} class and then registering this class
758
+ with the {YARD::CLI::CommandParser.commands} list. For instance:
759
+
760
+ YARD::CLI::CommandParser.commands[:my_command] = MyCommandClass
761
+
762
+ The above line will enable the user to execute `yard my_command [options]`.
763
+
764
+ ## `yard diff` command to object-diff two versions of a project (0.6.0)
765
+
766
+ One of the built-in commands that comes with the new `yard` executable is the
767
+ ability to do object-oriented diffing across multiple versions of the same
768
+ project, either by 2 versions of a gem, or 2 working copies. Just like
769
+ regular diffing tells you which lines have been added/removed in a file,
770
+ object diffing allows you to see what classes/methods/modules have been
771
+ added/removed between versions of a codebase.
772
+
773
+ For an overview of how to use `yard diff`, see [YARD Object Oriented Diffing](https://gnuu.org/2010/06/26/yard-object-oriented-diffing/).
774
+
775
+ ## `yard stats` to display statistics and undocumented objects (0.6.0)
776
+
777
+ YARD now outputs the following statistics when `yard stats` is run:
778
+
779
+ Files: 125
780
+ Modules: 35 ( 4 undocumented)
781
+ Classes: 139 ( 29 undocumented)
782
+ Constants: 53 ( 20 undocumented)
783
+ Methods: 602 ( 70 undocumented)
784
+ 85.16% documented
785
+
786
+ Note that these statistics are based on what you have set to show in your
787
+ documentation. If you use `@private` tags and/or do not display
788
+ private/protected methods in your documentation, these will not show up as
789
+ undocumented. Therefore this metric is contextual.
790
+
791
+ You can also specifically list all undocumented objects (and their file
792
+ locations) with the `--list-undoc` option.
793
+
794
+ ## Added `--asset` option to `yardoc` (0.6.0)
795
+
796
+ The `yardoc` command can now take the `--asset` option to copy over
797
+ files/directories (recursively) to the output path after generating
798
+ documentation. The format of the argument is "from:to" where from is the
799
+ source path and to is the destination. For instance, YARD uses the following
800
+ syntax in the `.yardopts` file to copy over image assets from the
801
+ 'docs/images' directory into the 'images' directory after generating HTML:
802
+
803
+ --asset docs/images:images
804
+
805
+ ## New template API (0.6.0)
806
+
807
+ The new template API allows for easier insertion of sections within an
808
+ inherited template. You should no longer need to insert by index, an
809
+ error-prone process that could break when a template is updated. Instead of:
810
+
811
+ sections.last.place(:my_section).before(:another_section)
812
+
813
+ use:
814
+
815
+ sections.place(:my_section).before_any(:another_section)
816
+
817
+ You can see more in the {file:docs/Templates.md#Inserting_and_Traversing_Sections}
818
+ document.
819
+
820
+ ## HTML template now adds inline Table of Contents for extra files pages (0.6.0)
821
+
822
+ A table of contents is now generated dynamically using JavaScript for extra
823
+ file pages (such as README's, or this document). It is generated based off the
824
+ headers (h1,h2,... tags) used in the document, and can be floated to the
825
+ right or listed inline on the page.
826
+
827
+ ## Ad-hoc tag registration via `yardoc` CLI (`--tag`, etc.) (0.6.0)
828
+
829
+ Simple meta-data tags can now be added at the command-line and registered to
830
+ display in templates in a number of pre-defined ways. For instance, to create
831
+ a freeform text tag, use the following:
832
+
833
+ --tag my_tag_name:"My Tag Title"
834
+
835
+ You can also create a "typed" tag (similar to `@return`), a typed named tag
836
+ (similar to `@param`) as well as various combinations. The full list of
837
+ options are listed in `yardoc --help` under the "Tag Options" section.
838
+
839
+ If you wish to create a tag to store data but do not wish to show this data
840
+ in the templates, use the `--hide-tag` option to hide it from generated output:
841
+
842
+ --hide-tag my_tag_name
843
+
844
+ ## Added `--transitive-tags` to register transitive tags (0.6.0)
845
+
846
+ Transitive tags are tags that apply to all descendants of a namespace (class
847
+ or module) when documented on that namespace. For instance, the `@since` tag
848
+ is a transitive tag. Applying `@since` to a class will automatically apply
849
+ `@since` to all methods in the class. Creating a `@since` tag directly on a
850
+ method will override the inherited value.
851
+
852
+ You can specify transitive tags on the command-line by using this option. Note
853
+ that the tags must already exist (built-in or created with the `--tag` option)
854
+ to be specified as transitive. If you wish to do this programmatically, see
855
+ the {YARD::Tags::Library.transitive_tags} attribute.
856
+
857
+ ## `yardoc` now displays RDoc-like statistics (`--no-stats` to hide) (0.6.0)
858
+
859
+ As seen in the `yard stats` feature overview, `yardoc` displays RDoc-like
860
+ statistics when it is run. The output is equivalent to typing `yard stats`.
861
+ To hide this output when yardoc is run, use `--no-stats`.
862
+
863
+ ## `yri` now works on constants (0.6.0)
864
+
865
+ Templates have now been added for text view of constants, which displays any
866
+ documentation and the constant value.
867
+
868
+ ## Plugins are no longer auto-loaded (added `--plugin` switch) (0.6.2)
869
+
870
+ This is a backwards-incompatible change that disables plugins from automatically
871
+ loading when YARD starts up. From now on, you should manually declare which
872
+ plugins your project is using by adding `--plugin PLUGINNAME` to a `.yardopts`
873
+ file in the root of your project. You can also re-enable autoloaded plugins
874
+ by setting `load_plugins` to true in your configuration file (`yard config load_plugins true`,
875
+ see next item). You can also set `autoload_plugins` to a list of plugins
876
+ to be automatically loaded on start.
877
+
878
+ If you are a YARD plugin author, please make sure to inform your users of these
879
+ changes.
880
+
881
+ Note that `--plugin` switches passed on the commandline (not via `.yardopts`)
882
+ are parsed before commands are loaded, and therefore can add in new CLI commands.
883
+
884
+ ## Added `YARD::Config` API and `~/.yard/config` configuration file (0.6.2)
885
+
886
+ There is a new global configuration API that can be accessed programmatically
887
+ and set via the `~/.yard/config` file. The file is encoded as a YAML file,
888
+ and looks like:
889
+
890
+ :load_plugins: false
891
+ :ignored_plugins:
892
+ - my_plugin
893
+ - my_other_plugin
894
+ :autoload_plugins:
895
+ - my_autoload_plugin
896
+ :safe_mode: false
897
+
898
+ You can also set configuration options via the command-line (see next item).
899
+
900
+ ## Added `yard config` command to view/edit configuration (0.6.2)
901
+
902
+ A new `yard config` command was created to view or edit the configuration
903
+ file via the commandline.
904
+
905
+ * To view the current configuration use `yard config --list`.
906
+ * To view a specific item use `yard config ITEMNAME`
907
+ * To modify an item value use `yard config ITEMNAME VALUE`
908
+
909
+ ## Added `yard server -t` template path switch (0.6.2)
910
+
911
+ The `yard server` command now accepts `-t` or `--template-path` to register
912
+ a new template path for template customization.
913
+
914
+ ## Added `YARD::Server.register_static_path` for static server assets (0.6.2)
915
+
916
+ The server now supports a command to register static asset paths. If you are
917
+ extending the YARD::Server modules, make sure to register your asset paths
918
+ through this method.
919
+
920
+ ## YARD::Registry is now thread local (0.6.5)
921
+
922
+ Creating a new thread will now implicitly load a new Registry that can be used
923
+ to parse and process new code objects independently of the other threads. Note
924
+ that this means you can no longer use the Registry across threads; you must
925
+ either access the threadlocal object directly, or synchronize threads to do
926
+ the processing in the initial registry's thread.
927
+
928
+ ## Support for ripper gem in Ruby 1.8.7 (0.6.5)
929
+
930
+ YARD now supports the Ruby 1.8.7 port of the `ripper` gem to improve parsing
931
+ of source, both in terms of performance and functionality. When the `ripper`
932
+ gem is available, YARD will use the "new-style" handlers. You can take advantage
933
+ of this functionality by performing a `gem install ripper`.
934
+
935
+
936
+ What's New in 0.5.x?
937
+ ====================
938
+
939
+ 1. **Support for documenting native Ruby C code** (0.5.0)
940
+ 2. **Incremental parsing and output generation with `yardoc -c`** (0.5.0, 0.5.3)
941
+ 2. **Improved `yri` support to perform lookups on installed Gems** (0.5.0)
942
+ 3. **Added `yardoc --default-return` and `yardoc --hide-void-return`** (0.5.0)
943
+ 4. **Multiple syntax highlighting language support** (0.5.0)
944
+ 5. **New .yardoc format** (0.5.0)
945
+ 6. **Support for yard-doc-* gem packages as hosted .yardoc dbs** (0.5.1)
946
+ 7. **Support for extra search paths in `yri`** (0.5.1)
947
+ 8. **Generating HTML docs now adds frames view** (0.5.3)
948
+ 9. **Tree view for class list** (0.5.3)
949
+ 10. **Ability to specify markup format of extra files** (0.5.3)
950
+ 11. **Keyboard shortcuts for default HTML template** (0.5.4)
951
+
952
+ Support for documenting native Ruby C code (0.5.0)
953
+ --------------------------------------------------
954
+
955
+ It is now possible to document native Ruby extensions with YARD with a new
956
+ C parser mostly borrowed from RDoc. This enables the ability to document
957
+ Ruby's core and stdlibs which will be hosted on https://yardoc.org/docs. In
958
+ addition, the .yardoc dump for the Ruby-core classes will become available
959
+ as an installable gem for yri support (see #3).
960
+
961
+ Incremental parsing and output generation with `yardoc -c` (0.5.0, 0.5.3)
962
+ -------------------------------------------------------------------------
963
+
964
+ <p class="note">Note: in 0.5.3 and above you must use <tt>--incremental</tt>
965
+ to incrementally generate HTML, otherwise only parsing will be done
966
+ incrementally but HTML will be generated with all objects. <tt>--incremental</tt>
967
+ implies <tt>-c</tt>, so no need to specify them both.</p>
968
+
969
+ YARD now compares file checksums before parsing when using `yardoc -c`
970
+ (aka `yardoc --use-cache`) to do incremental parsing of only the files that
971
+ have changed. HTML (or other output format) generation will also only be
972
+ done on the objects that were parsed from changed files (\*). This makes doing
973
+ a documentation development cycle much faster for quick HTML previews. Just
974
+ remember that when using incremental output generation, the index will not
975
+ be rebuilt and inter-file links might not hook up right, so it is best to
976
+ perform a full rebuild at the end of such previews.
977
+
978
+ (\*) Only for versions prior to 0.5.3. For 0.5.3+, use `--incremental` for
979
+ incremental HTML output.
980
+
981
+ Improved `yri` support to perform lookups on installed Gems (0.5.0)
982
+ -------------------------------------------------------------------
983
+
984
+ The `yri` executable can now perform lookups on gems that have been parsed
985
+ by yard. Therefore, to use this command you must first parse all gems with
986
+ YARD. To parse all gems, use the following command:
987
+
988
+ $ sudo yardoc --build-gems
989
+
990
+ The above command builds a .yardoc file for all installed gems in the
991
+ respective gem directory. If you do not have write access to the gem path,
992
+ YARD will write the yardoc file to `~/.yard/gem_index/NAME-VERSION.yardoc`.
993
+
994
+ Note: you can also use `--re-build-gems` to force re-parsing of all gems.
995
+
996
+ You can now do lookups with yri:
997
+
998
+ $ yri JSON
999
+
1000
+ All lookups are cached to `~/.yard/yri_cache` for quicker lookups the second
1001
+ time onward.
1002
+
1003
+ Added `yardoc --default-return` and `yardoc --hide-void-return` (0.5.0)
1004
+ -----------------------------------------------------------------------
1005
+
1006
+ YARD defaults to displaying (Object) as the default return type of any
1007
+ method that has not declared a @return tag. To customize the default
1008
+ return type, you can specify:
1009
+
1010
+ $ yardoc --default-return 'MyDefaultType'
1011
+
1012
+ You can also use the empty string to list no return type.
1013
+
1014
+ In addition, you can use --hide-void-return to ignore any method that
1015
+ defines itself as a void type by: `@return [void]`
1016
+
1017
+ Multiple syntax highlighting language support (0.5.0)
1018
+ -----------------------------------------------------
1019
+
1020
+ YARD now supports the ability to specify a language type for code blocks in
1021
+ docstrings. Although no actual highlighting support is added for any language
1022
+ but Ruby, you can add your own support by writing your own helper method:
1023
+
1024
+ # Where LANGNAME is the language:
1025
+ def html_syntax_highlight_LANGNAME(source)
1026
+ # return highlighted HTML
1027
+ end
1028
+
1029
+ To use this language in code blocks, prefix the block with `!!!LANGNAME`:
1030
+
1031
+ !!!plain
1032
+ !!!python
1033
+ def python_code(self):
1034
+ return self
1035
+
1036
+ By the same token. you can now use `!!!plain` to ignore highlighting for
1037
+ a specific code block.
1038
+
1039
+ New .yardoc format (0.5.0)
1040
+ --------------------------
1041
+
1042
+ To make the above yri support possible, the .yardoc format was redesigned
1043
+ to be a directory instead of a file. YARD can still load old .yardoc files,
1044
+ but they will be automatically upgraded if re-saved. The new .yardoc format
1045
+ does have a larger memory footprint, but this will hopefully be optimized
1046
+ downward.
1047
+
1048
+ Support for yard-doc-* gem packages as hosted .yardoc dbs (0.5.1)
1049
+ -----------------------------------------------------------------
1050
+
1051
+ You can now install special YARD plugin gems titled yard-doc-NAME to get
1052
+ packaged a .yardoc database. This will enable yri lookups or building docs
1053
+ for the gem without the code.
1054
+
1055
+ One main use for this is the `yard-doc-core` package, which enabled yri
1056
+ support for Ruby core classes (stdlib coming soon as `yard-doc-stdlib`).
1057
+ To install it, simply:
1058
+
1059
+ $ sudo gem install yard-doc-core
1060
+ # now you can use:
1061
+ $ yri String
1062
+
1063
+ This will by default install the 1.9.1 core library. To install a library
1064
+ for a specific version of Ruby, use the `--version` switch on gem:
1065
+
1066
+ $ sudo gem install --version '= 1.8.6' yard-doc-core
1067
+
1068
+ Support for extra search paths in `yri` (0.5.1)
1069
+ -----------------------------------------------
1070
+
1071
+ You can now add custom paths to non-gem .yardoc files
1072
+ by adding them as newline separated paths in `~/.yard/yri_search_paths`.
1073
+
1074
+ Generating HTML docs now adds frames view (0.5.3)
1075
+ -------------------------------------------------
1076
+
1077
+ `yardoc` will now create a `frames.html` file when generating HTML documents
1078
+ which allows the user to view documentation inside frames, for those users who
1079
+ still find frames beneficial.
1080
+
1081
+ Tree view for class list (0.5.3)
1082
+ --------------------------------
1083
+
1084
+ The class list now displays as an expandable tree view to better organized an
1085
+ otherwise cluttered namespace. If you properly namespace your less important
1086
+ classes (like Rails timezone classes), they will not take up space in the
1087
+ class list unless the user looks for them.
1088
+
1089
+ Ability to specify markup format of extra files (0.5.3)
1090
+ -------------------------------------------------------
1091
+
1092
+ You can now specify the markup format of an extra file (like README) at the
1093
+ top of the file with a shebang-like line:
1094
+
1095
+ #!textile
1096
+ contents here
1097
+
1098
+ The above file contents will be rendered with a textile markup engine
1099
+ (eg. RedCloth).
1100
+
1101
+ Keyboard shortcuts for default HTML template (0.5.4)
1102
+ ----------------------------------------------------
1103
+
1104
+ You can now access the "Class List", "Method List" and "File List" with the
1105
+ 'c', 'm' and 'f' keyboard shortcuts in the default HTML template, allowing
1106
+ for keyboard-only navigation around YARD documentation.
1107
+
1108
+ API for registering custom parsers (0.5.6)
1109
+ ------------------------------------------
1110
+
1111
+ You can now register parsers for custom source languages by calling the
1112
+ following method:
1113
+
1114
+ SourceParser.register_parser_type(:java, MyJavaParser, 'java')
1115
+
1116
+ The parser class MyJavaParser should be a subclass of {YARD::Parser::Base},
1117
+ and the last argument is a set of extensions (string, array or regexp). You
1118
+ can read more about registering parsers at the {YARD::Parser::SourceParser}
1119
+ class documentation.
1120
+
1121
+
1122
+ What's New in 0.4.x?
1123
+ ====================
1124
+
1125
+ 1. **New templating engine and templates**
1126
+ 2. **yardoc `--query` argument**
1127
+ 3. **Greatly expanded API documentation**
1128
+ 4. **New plugin support**
1129
+ 5. **New tags (@abstract, @private)**
1130
+ 6. **Default rake task is now `rake yard`**
1131
+
1132
+ New templating engine and templates
1133
+ -----------------------------------
1134
+
1135
+ The templates were redesigned, most notably removing the ugly frameset, adding
1136
+ search to the class/method lists, simplifying the layout and making things
1137
+ generally prettier. You should also notice that more tags are now visible in
1138
+ the templates such as @todo, the new @abstract and @note tags and some others
1139
+ that existed but were previously omitted from the generated documentation.
1140
+
1141
+ There is also a new templating engine (based on the tadpole templating library)
1142
+ to allow for much more user customization. You can read about it in
1143
+ {file:docs/Templates.md}.
1144
+
1145
+ yardoc `--query` argument
1146
+ -------------------------
1147
+
1148
+ The yardoc command-line tool now supports queries to select which classes,
1149
+ modules or methods to include in documentation based on their data or meta-data.
1150
+ For instance, you can now generate documentation for your "public" API only by
1151
+ adding "@api public" to each of your public API methods/classes and using
1152
+ the following argument:
1153
+
1154
+ --query '@api.text == "public"'
1155
+
1156
+ More information on queries is in the {file:README.md}.
1157
+
1158
+ Greatly expanded API documentation
1159
+ ----------------------------------
1160
+
1161
+ Last release focused on many how-to and architecture documents to explain
1162
+ the design of YARD, but many of the actual API classes/methods were still
1163
+ left undocumented. This release marks a focus on getting YARD's own documentation
1164
+ up to par so that it can serve as an official reference on the recommended
1165
+ conventions to use when documenting code.
1166
+
1167
+ New plugin support
1168
+ ------------------
1169
+
1170
+ YARD now supports loading of plugins via RubyGems. Any gem named `yard-*` or
1171
+ `yard_*` will now be loaded when YARD starts up. Note that the '-' separator
1172
+ is the recommended naming scheme.
1173
+
1174
+ To ignore plugins, add the gem names to `~/.yard/ignored_plugins` on separate
1175
+ lines (or separated by whitespace).
1176
+
1177
+ New tags (@abstract, @private)
1178
+ ------------------------------
1179
+
1180
+ Two new tags were added to the list of builtin meta-tags in YARD. `@abstract`
1181
+ marks a class/module/method as abstract while `@private` marks an object
1182
+ as "private". The latter tag is used in situations where an object is public
1183
+ due to Ruby's own visibility limitations (constants, classes and modules
1184
+ can never be private) but not actually part of your public API. You should
1185
+ use this tag sparingly, as it is not meant to be an equivalent to RDoc's
1186
+ `:nodoc:` tag. Remember, YARD recommends documenting private objects too.
1187
+ This tag exists so that you can create a query (`--query !@private`) to
1188
+ ignore all of these private objects in your documentation. You can also
1189
+ use the new `--no-private` switch, which is a shortcut to the aforementioned
1190
+ query. You can read more about the new tags in the {file:docs/GettingStarted.md}
1191
+ guide.
1192
+
1193
+ Default rake task is now `rake yard`
1194
+ ------------------------------------
1195
+
1196
+ Not a big change, but anyone using the default "rake yardoc" task should
1197
+ update their scripts:
1198
+
1199
+ [https://github.com/lsegal/yard/commit/ad38a68dd73898b06bd5d0a1912b7d815878fae0](https://github.com/lsegal/yard/commit/ad38a68dd73898b06bd5d0a1912b7d815878fae0)
1200
+
1201
+
1202
+ What's New in 0.2.3.x?
1203
+ ======================
1204
+
1205
+ 1. **Full Ruby 1.9 support**
1206
+ 2. **New parser code and handler API for 1.9**
1207
+ 3. **A new `@overload` tag**
1208
+ 4. **Better documentation**
1209
+ 5. **Template changes and bug fixes**
1210
+
1211
+ Full Ruby 1.9 support
1212
+ ---------------------
1213
+
1214
+ YARD's development actually focuses primarily on 1.9 from the get-go, so it is
1215
+ not an afterthought. All features are first implemented for compatibility with
1216
+ 1.9, but of course all functionality is also tested in 1.8.x. YARD 0.2.2 was
1217
+ mostly compatible with 1.9, but the new release improves and extends in certain
1218
+ areas where compatibility was lacking. The new release should be fully functional
1219
+ in Ruby 1.9.
1220
+
1221
+ New parser code and handler API for 1.9
1222
+ ---------------------------------------
1223
+
1224
+ Using Ruby 1.9 also gives YARD the advantage of using the new `ripper` library
1225
+ which was added to stdlib. The ripper parser is Ruby's official answer to
1226
+ projects like ParseTree and ruby2ruby. Ripper allows access to the AST as it
1227
+ is parsed by the Ruby compiler. This has some large benefits over alternative
1228
+ projects:
1229
+
1230
+ 1. It is officially supported and maintained by the Ruby core team.
1231
+ 2. The AST is generated directly from the exact same code that drives the
1232
+ compiler, meaning anything that compiles is guaranteed to generate the
1233
+ equivalent AST.
1234
+ 3. It needs no hacks, gems or extra libs and works out of the box in 1.9.
1235
+ 4. It's *fast*.
1236
+
1237
+ Having the AST means that developers looking to extend YARD have much better
1238
+ access to the parsed code than in previous versions. The only caveat is that
1239
+ this library is not back-compatible to 1.8.x. Because of this, there are
1240
+ subtle changes to the handler extension API that developers use to extend YARD.
1241
+ Namely, there is now a standard API for 1.9 and a "legacy" API that can run in
1242
+ both 1.8.x and 1.9 if needed. A developer can still use the legacy API to write
1243
+ handlers that are compatible for both 1.8.x and 1.9 in one shot, or decide to
1244
+ implement the handler using both APIs. Realize that the benefit of using the new
1245
+ API means 1.9 users will get a 2.5x parsing speed increase over running the legacy
1246
+ handlers (this is *in addition to* the ~1.8x speed increase of using YARV over MRI).
1247
+
1248
+ A new `@overload` tag
1249
+ ---------------------
1250
+
1251
+ The new `@overload` tag enables users to document methods that take multiple
1252
+ parameters depending on context. This is basically equivalent to RDoc's call-seq,
1253
+ but with a name that is more akin to the OOP concept of method overloading
1254
+ that is actually being employed. Here's an example:
1255
+
1256
+ # @overload def to_html(html, autolink = true)
1257
+ # This docstring describes the specific overload only.
1258
+ # @param [String] html the HTML
1259
+ # @param [Boolean] autolink whether or not to automatically link
1260
+ # URL references
1261
+ # @overload def to_html(html, opts = {})
1262
+ # @param [String] html the HTML
1263
+ # @param [Hash] opts any attributes to add to the root HTML node
1264
+ def to_html(*args)
1265
+ # split args depending on context
1266
+ end
1267
+
1268
+ As you can see each overload takes its own nested tags (including a docstring)
1269
+ as if it were its own method. This allows "virtual" overloading behaviour at
1270
+ the API level to make Ruby look like overload-aware languages without caring
1271
+ about the implementation details required to add the behaviour.
1272
+
1273
+ It is still recommended practice, however, to stay away from overloading when
1274
+ possible and document the types of each method's real parameters. This allows
1275
+ toolkits making use of YARD to get accurate type information for your methods,
1276
+ for instance, allowing IDE autocompletion. There are, of course, situations
1277
+ where overload just makes more sense.
1278
+
1279
+ Better documentation
1280
+ --------------------
1281
+
1282
+ The first few iterations of YARD were very much a proof of concept. Few people
1283
+ were paying attention and it was really just pieced together to see what was
1284
+ feasible. Now that YARD is gaining interest, there are many developers that
1285
+ want to take advantage of its extensibility support to do some really cool stuff.
1286
+ Considerable time was spent for this release documenting, at a high level, what
1287
+ YARD can do and how it can be done. Expect this documentation to be extended and
1288
+ improved in future releases.
1289
+
1290
+ Template changes and bug fixes
1291
+ ------------------------------
1292
+
1293
+ Of course no new release would be complete without fixing the old broken code.
1294
+ Some tags existed but were not present in generated documentation. The templates
1295
+ were mostly fixed to add the major omitted tags. In addition to template adjustments,
1296
+ many parsing bugs were ironed out to make YARD much more stable with existing projects
1297
+ (Rails, HAML, Sinatra, Ramaze, etc.).