gitlab-rdoc 6.3.2
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.
- checksums.yaml +7 -0
- data/CONTRIBUTING.rdoc +220 -0
- data/CVE-2013-0256.rdoc +49 -0
- data/ExampleMarkdown.md +37 -0
- data/ExampleRDoc.rdoc +208 -0
- data/Gemfile +12 -0
- data/History.rdoc +1666 -0
- data/LEGAL.rdoc +50 -0
- data/LICENSE.rdoc +57 -0
- data/README.rdoc +133 -0
- data/RI.rdoc +57 -0
- data/Rakefile +101 -0
- data/TODO.rdoc +59 -0
- data/bin/console +7 -0
- data/bin/setup +6 -0
- data/exe/rdoc +44 -0
- data/exe/ri +12 -0
- data/lib/rdoc/alias.rb +112 -0
- data/lib/rdoc/anon_class.rb +11 -0
- data/lib/rdoc/any_method.rb +361 -0
- data/lib/rdoc/attr.rb +176 -0
- data/lib/rdoc/class_module.rb +802 -0
- data/lib/rdoc/code_object.rb +421 -0
- data/lib/rdoc/code_objects.rb +6 -0
- data/lib/rdoc/comment.rb +250 -0
- data/lib/rdoc/constant.rb +187 -0
- data/lib/rdoc/context/section.rb +232 -0
- data/lib/rdoc/context.rb +1266 -0
- data/lib/rdoc/cross_reference.rb +202 -0
- data/lib/rdoc/encoding.rb +136 -0
- data/lib/rdoc/erb_partial.rb +19 -0
- data/lib/rdoc/erbio.rb +42 -0
- data/lib/rdoc/extend.rb +10 -0
- data/lib/rdoc/generator/darkfish.rb +790 -0
- data/lib/rdoc/generator/json_index.rb +300 -0
- data/lib/rdoc/generator/markup.rb +160 -0
- data/lib/rdoc/generator/pot/message_extractor.rb +68 -0
- data/lib/rdoc/generator/pot/po.rb +84 -0
- data/lib/rdoc/generator/pot/po_entry.rb +141 -0
- data/lib/rdoc/generator/pot.rb +98 -0
- data/lib/rdoc/generator/ri.rb +31 -0
- data/lib/rdoc/generator/template/darkfish/.document +0 -0
- data/lib/rdoc/generator/template/darkfish/_footer.rhtml +5 -0
- data/lib/rdoc/generator/template/darkfish/_head.rhtml +22 -0
- data/lib/rdoc/generator/template/darkfish/_sidebar_VCS_info.rhtml +19 -0
- data/lib/rdoc/generator/template/darkfish/_sidebar_classes.rhtml +9 -0
- data/lib/rdoc/generator/template/darkfish/_sidebar_extends.rhtml +15 -0
- data/lib/rdoc/generator/template/darkfish/_sidebar_in_files.rhtml +9 -0
- data/lib/rdoc/generator/template/darkfish/_sidebar_includes.rhtml +15 -0
- data/lib/rdoc/generator/template/darkfish/_sidebar_installed.rhtml +15 -0
- data/lib/rdoc/generator/template/darkfish/_sidebar_methods.rhtml +12 -0
- data/lib/rdoc/generator/template/darkfish/_sidebar_navigation.rhtml +11 -0
- data/lib/rdoc/generator/template/darkfish/_sidebar_pages.rhtml +12 -0
- data/lib/rdoc/generator/template/darkfish/_sidebar_parent.rhtml +11 -0
- data/lib/rdoc/generator/template/darkfish/_sidebar_search.rhtml +14 -0
- data/lib/rdoc/generator/template/darkfish/_sidebar_sections.rhtml +11 -0
- data/lib/rdoc/generator/template/darkfish/_sidebar_table_of_contents.rhtml +18 -0
- data/lib/rdoc/generator/template/darkfish/class.rhtml +172 -0
- data/lib/rdoc/generator/template/darkfish/css/fonts.css +167 -0
- data/lib/rdoc/generator/template/darkfish/css/rdoc.css +639 -0
- data/lib/rdoc/generator/template/darkfish/fonts/Lato-Light.ttf +0 -0
- data/lib/rdoc/generator/template/darkfish/fonts/Lato-LightItalic.ttf +0 -0
- data/lib/rdoc/generator/template/darkfish/fonts/Lato-Regular.ttf +0 -0
- data/lib/rdoc/generator/template/darkfish/fonts/Lato-RegularItalic.ttf +0 -0
- data/lib/rdoc/generator/template/darkfish/fonts/SourceCodePro-Bold.ttf +0 -0
- data/lib/rdoc/generator/template/darkfish/fonts/SourceCodePro-Regular.ttf +0 -0
- data/lib/rdoc/generator/template/darkfish/images/add.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/arrow_up.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/brick.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/brick_link.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/bug.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/bullet_black.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/bullet_toggle_minus.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/bullet_toggle_plus.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/date.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/delete.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/find.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/loadingAnimation.gif +0 -0
- data/lib/rdoc/generator/template/darkfish/images/macFFBgHack.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/package.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/page_green.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/page_white_text.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/page_white_width.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/plugin.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/ruby.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/tag_blue.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/tag_green.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/transparent.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/wrench.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/wrench_orange.png +0 -0
- data/lib/rdoc/generator/template/darkfish/images/zoom.png +0 -0
- data/lib/rdoc/generator/template/darkfish/index.rhtml +22 -0
- data/lib/rdoc/generator/template/darkfish/js/darkfish.js +84 -0
- data/lib/rdoc/generator/template/darkfish/js/search.js +110 -0
- data/lib/rdoc/generator/template/darkfish/page.rhtml +18 -0
- data/lib/rdoc/generator/template/darkfish/servlet_not_found.rhtml +18 -0
- data/lib/rdoc/generator/template/darkfish/servlet_root.rhtml +62 -0
- data/lib/rdoc/generator/template/darkfish/table_of_contents.rhtml +58 -0
- data/lib/rdoc/generator/template/json_index/.document +1 -0
- data/lib/rdoc/generator/template/json_index/js/navigation.js +105 -0
- data/lib/rdoc/generator/template/json_index/js/searcher.js +229 -0
- data/lib/rdoc/generator.rb +51 -0
- data/lib/rdoc/ghost_method.rb +7 -0
- data/lib/rdoc/i18n/locale.rb +102 -0
- data/lib/rdoc/i18n/text.rb +126 -0
- data/lib/rdoc/i18n.rb +10 -0
- data/lib/rdoc/include.rb +10 -0
- data/lib/rdoc/known_classes.rb +73 -0
- data/lib/rdoc/markdown/entities.rb +2132 -0
- data/lib/rdoc/markdown/literals.kpeg +23 -0
- data/lib/rdoc/markdown/literals.rb +417 -0
- data/lib/rdoc/markdown.kpeg +1237 -0
- data/lib/rdoc/markdown.rb +16685 -0
- data/lib/rdoc/markup/attr_changer.rb +23 -0
- data/lib/rdoc/markup/attr_span.rb +36 -0
- data/lib/rdoc/markup/attribute_manager.rb +409 -0
- data/lib/rdoc/markup/attributes.rb +71 -0
- data/lib/rdoc/markup/blank_line.rb +28 -0
- data/lib/rdoc/markup/block_quote.rb +15 -0
- data/lib/rdoc/markup/document.rb +165 -0
- data/lib/rdoc/markup/formatter.rb +266 -0
- data/lib/rdoc/markup/hard_break.rb +32 -0
- data/lib/rdoc/markup/heading.rb +79 -0
- data/lib/rdoc/markup/include.rb +43 -0
- data/lib/rdoc/markup/indented_paragraph.rb +48 -0
- data/lib/rdoc/markup/list.rb +102 -0
- data/lib/rdoc/markup/list_item.rb +100 -0
- data/lib/rdoc/markup/paragraph.rb +29 -0
- data/lib/rdoc/markup/parser.rb +575 -0
- data/lib/rdoc/markup/pre_process.rb +296 -0
- data/lib/rdoc/markup/raw.rb +70 -0
- data/lib/rdoc/markup/regexp_handling.rb +41 -0
- data/lib/rdoc/markup/rule.rb +21 -0
- data/lib/rdoc/markup/table.rb +47 -0
- data/lib/rdoc/markup/to_ansi.rb +94 -0
- data/lib/rdoc/markup/to_bs.rb +77 -0
- data/lib/rdoc/markup/to_html.rb +444 -0
- data/lib/rdoc/markup/to_html_crossref.rb +176 -0
- data/lib/rdoc/markup/to_html_snippet.rb +285 -0
- data/lib/rdoc/markup/to_joined_paragraph.rb +47 -0
- data/lib/rdoc/markup/to_label.rb +75 -0
- data/lib/rdoc/markup/to_markdown.rb +192 -0
- data/lib/rdoc/markup/to_rdoc.rb +362 -0
- data/lib/rdoc/markup/to_table_of_contents.rb +89 -0
- data/lib/rdoc/markup/to_test.rb +70 -0
- data/lib/rdoc/markup/to_tt_only.rb +121 -0
- data/lib/rdoc/markup/verbatim.rb +84 -0
- data/lib/rdoc/markup.rb +867 -0
- data/lib/rdoc/meta_method.rb +7 -0
- data/lib/rdoc/method_attr.rb +419 -0
- data/lib/rdoc/mixin.rb +121 -0
- data/lib/rdoc/normal_class.rb +93 -0
- data/lib/rdoc/normal_module.rb +74 -0
- data/lib/rdoc/options.rb +1285 -0
- data/lib/rdoc/parser/c.rb +1225 -0
- data/lib/rdoc/parser/changelog.rb +335 -0
- data/lib/rdoc/parser/markdown.rb +24 -0
- data/lib/rdoc/parser/rd.rb +23 -0
- data/lib/rdoc/parser/ripper_state_lex.rb +590 -0
- data/lib/rdoc/parser/ruby.rb +2327 -0
- data/lib/rdoc/parser/ruby_tools.rb +167 -0
- data/lib/rdoc/parser/simple.rb +61 -0
- data/lib/rdoc/parser/text.rb +12 -0
- data/lib/rdoc/parser.rb +277 -0
- data/lib/rdoc/rd/block_parser.rb +1056 -0
- data/lib/rdoc/rd/block_parser.ry +639 -0
- data/lib/rdoc/rd/inline.rb +72 -0
- data/lib/rdoc/rd/inline_parser.rb +1208 -0
- data/lib/rdoc/rd/inline_parser.ry +593 -0
- data/lib/rdoc/rd.rb +100 -0
- data/lib/rdoc/rdoc.rb +579 -0
- data/lib/rdoc/require.rb +52 -0
- data/lib/rdoc/ri/driver.rb +1572 -0
- data/lib/rdoc/ri/formatter.rb +6 -0
- data/lib/rdoc/ri/paths.rb +171 -0
- data/lib/rdoc/ri/store.rb +7 -0
- data/lib/rdoc/ri/task.rb +71 -0
- data/lib/rdoc/ri.rb +21 -0
- data/lib/rdoc/rubygems_hook.rb +246 -0
- data/lib/rdoc/servlet.rb +451 -0
- data/lib/rdoc/single_class.rb +26 -0
- data/lib/rdoc/stats/normal.rb +58 -0
- data/lib/rdoc/stats/quiet.rb +60 -0
- data/lib/rdoc/stats/verbose.rb +46 -0
- data/lib/rdoc/stats.rb +462 -0
- data/lib/rdoc/store.rb +979 -0
- data/lib/rdoc/task.rb +329 -0
- data/lib/rdoc/text.rb +304 -0
- data/lib/rdoc/token_stream.rb +119 -0
- data/lib/rdoc/tom_doc.rb +263 -0
- data/lib/rdoc/top_level.rb +289 -0
- data/lib/rdoc/version.rb +8 -0
- data/lib/rdoc.rb +201 -0
- data/man/ri.1 +247 -0
- data/rdoc.gemspec +249 -0
- metadata +279 -0
data/lib/rdoc/version.rb
ADDED
data/lib/rdoc.rb
ADDED
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
$DEBUG_RDOC = nil
|
|
3
|
+
|
|
4
|
+
# :main: README.rdoc
|
|
5
|
+
|
|
6
|
+
##
|
|
7
|
+
# RDoc produces documentation for Ruby source files by parsing the source and
|
|
8
|
+
# extracting the definition for classes, modules, methods, includes and
|
|
9
|
+
# requires. It associates these with optional documentation contained in an
|
|
10
|
+
# immediately preceding comment block then renders the result using an output
|
|
11
|
+
# formatter.
|
|
12
|
+
#
|
|
13
|
+
# For a simple introduction to writing or generating documentation using RDoc
|
|
14
|
+
# see the README.
|
|
15
|
+
#
|
|
16
|
+
# == Roadmap
|
|
17
|
+
#
|
|
18
|
+
# If you think you found a bug in RDoc see CONTRIBUTING@Bugs
|
|
19
|
+
#
|
|
20
|
+
# If you want to use RDoc to create documentation for your Ruby source files,
|
|
21
|
+
# see RDoc::Markup and refer to <tt>rdoc --help</tt> for command line usage.
|
|
22
|
+
#
|
|
23
|
+
# If you want to set the default markup format see
|
|
24
|
+
# RDoc::Markup@Supported+Formats
|
|
25
|
+
#
|
|
26
|
+
# If you want to store rdoc configuration in your gem (such as the default
|
|
27
|
+
# markup format) see RDoc::Options@Saved+Options
|
|
28
|
+
#
|
|
29
|
+
# If you want to write documentation for Ruby files see RDoc::Parser::Ruby
|
|
30
|
+
#
|
|
31
|
+
# If you want to write documentation for extensions written in C see
|
|
32
|
+
# RDoc::Parser::C
|
|
33
|
+
#
|
|
34
|
+
# If you want to generate documentation using <tt>rake</tt> see RDoc::Task.
|
|
35
|
+
#
|
|
36
|
+
# If you want to drive RDoc programmatically, see RDoc::RDoc.
|
|
37
|
+
#
|
|
38
|
+
# If you want to use the library to format text blocks into HTML or other
|
|
39
|
+
# formats, look at RDoc::Markup.
|
|
40
|
+
#
|
|
41
|
+
# If you want to make an RDoc plugin such as a generator or directive handler
|
|
42
|
+
# see RDoc::RDoc.
|
|
43
|
+
#
|
|
44
|
+
# If you want to write your own output generator see RDoc::Generator.
|
|
45
|
+
#
|
|
46
|
+
# If you want an overview of how RDoc works see CONTRIBUTING
|
|
47
|
+
#
|
|
48
|
+
# == Credits
|
|
49
|
+
#
|
|
50
|
+
# RDoc is currently being maintained by Eric Hodel <drbrain@segment7.net>.
|
|
51
|
+
#
|
|
52
|
+
# Dave Thomas <dave@pragmaticprogrammer.com> is the original author of RDoc.
|
|
53
|
+
#
|
|
54
|
+
# * The Ruby parser in rdoc/parse.rb is based heavily on the outstanding
|
|
55
|
+
# work of Keiju ISHITSUKA of Nippon Rational Inc, who produced the Ruby
|
|
56
|
+
# parser for irb and the rtags package.
|
|
57
|
+
|
|
58
|
+
module RDoc
|
|
59
|
+
|
|
60
|
+
##
|
|
61
|
+
# Exception thrown by any rdoc error.
|
|
62
|
+
|
|
63
|
+
class Error < RuntimeError; end
|
|
64
|
+
|
|
65
|
+
require 'rdoc/version'
|
|
66
|
+
|
|
67
|
+
##
|
|
68
|
+
# Method visibilities
|
|
69
|
+
|
|
70
|
+
VISIBILITIES = [:public, :protected, :private]
|
|
71
|
+
|
|
72
|
+
##
|
|
73
|
+
# Name of the dotfile that contains the description of files to be processed
|
|
74
|
+
# in the current directory
|
|
75
|
+
|
|
76
|
+
DOT_DOC_FILENAME = ".document"
|
|
77
|
+
|
|
78
|
+
##
|
|
79
|
+
# General RDoc modifiers
|
|
80
|
+
|
|
81
|
+
GENERAL_MODIFIERS = %w[nodoc].freeze
|
|
82
|
+
|
|
83
|
+
##
|
|
84
|
+
# RDoc modifiers for classes
|
|
85
|
+
|
|
86
|
+
CLASS_MODIFIERS = GENERAL_MODIFIERS
|
|
87
|
+
|
|
88
|
+
##
|
|
89
|
+
# RDoc modifiers for attributes
|
|
90
|
+
|
|
91
|
+
ATTR_MODIFIERS = GENERAL_MODIFIERS
|
|
92
|
+
|
|
93
|
+
##
|
|
94
|
+
# RDoc modifiers for constants
|
|
95
|
+
|
|
96
|
+
CONSTANT_MODIFIERS = GENERAL_MODIFIERS
|
|
97
|
+
|
|
98
|
+
##
|
|
99
|
+
# RDoc modifiers for methods
|
|
100
|
+
|
|
101
|
+
METHOD_MODIFIERS = GENERAL_MODIFIERS +
|
|
102
|
+
%w[arg args yield yields notnew not-new not_new doc]
|
|
103
|
+
|
|
104
|
+
##
|
|
105
|
+
# Loads the best available YAML library.
|
|
106
|
+
|
|
107
|
+
def self.load_yaml
|
|
108
|
+
begin
|
|
109
|
+
gem 'psych'
|
|
110
|
+
rescue NameError => e # --disable-gems
|
|
111
|
+
raise unless e.name == :gem
|
|
112
|
+
rescue Gem::LoadError
|
|
113
|
+
end
|
|
114
|
+
|
|
115
|
+
begin
|
|
116
|
+
require 'psych'
|
|
117
|
+
rescue ::LoadError
|
|
118
|
+
ensure
|
|
119
|
+
require 'yaml'
|
|
120
|
+
end
|
|
121
|
+
end
|
|
122
|
+
|
|
123
|
+
def self.home
|
|
124
|
+
rdoc_dir = begin
|
|
125
|
+
File.expand_path('~/.rdoc')
|
|
126
|
+
rescue ArgumentError
|
|
127
|
+
end
|
|
128
|
+
|
|
129
|
+
if File.directory?(rdoc_dir)
|
|
130
|
+
rdoc_dir
|
|
131
|
+
else
|
|
132
|
+
begin
|
|
133
|
+
# XDG
|
|
134
|
+
xdg_data_home = ENV["XDG_DATA_HOME"] || File.join(File.expand_path("~"), '.local', 'share')
|
|
135
|
+
unless File.exist?(xdg_data_home)
|
|
136
|
+
FileUtils.mkdir_p xdg_data_home
|
|
137
|
+
end
|
|
138
|
+
File.join xdg_data_home, "rdoc"
|
|
139
|
+
rescue Errno::EACCES
|
|
140
|
+
end
|
|
141
|
+
end
|
|
142
|
+
end
|
|
143
|
+
|
|
144
|
+
autoload :RDoc, 'rdoc/rdoc'
|
|
145
|
+
|
|
146
|
+
autoload :CrossReference, 'rdoc/cross_reference'
|
|
147
|
+
autoload :ERBIO, 'rdoc/erbio'
|
|
148
|
+
autoload :ERBPartial, 'rdoc/erb_partial'
|
|
149
|
+
autoload :Encoding, 'rdoc/encoding'
|
|
150
|
+
autoload :Generator, 'rdoc/generator'
|
|
151
|
+
autoload :Options, 'rdoc/options'
|
|
152
|
+
autoload :Parser, 'rdoc/parser'
|
|
153
|
+
autoload :Servlet, 'rdoc/servlet'
|
|
154
|
+
autoload :RI, 'rdoc/ri'
|
|
155
|
+
autoload :Stats, 'rdoc/stats'
|
|
156
|
+
autoload :Store, 'rdoc/store'
|
|
157
|
+
autoload :Task, 'rdoc/task'
|
|
158
|
+
autoload :Text, 'rdoc/text'
|
|
159
|
+
|
|
160
|
+
autoload :Markdown, 'rdoc/markdown'
|
|
161
|
+
autoload :Markup, 'rdoc/markup'
|
|
162
|
+
autoload :RD, 'rdoc/rd'
|
|
163
|
+
autoload :TomDoc, 'rdoc/tom_doc'
|
|
164
|
+
|
|
165
|
+
autoload :KNOWN_CLASSES, 'rdoc/known_classes'
|
|
166
|
+
|
|
167
|
+
autoload :TokenStream, 'rdoc/token_stream'
|
|
168
|
+
|
|
169
|
+
autoload :Comment, 'rdoc/comment'
|
|
170
|
+
|
|
171
|
+
require 'rdoc/i18n'
|
|
172
|
+
|
|
173
|
+
# code objects
|
|
174
|
+
#
|
|
175
|
+
# We represent the various high-level code constructs that appear in Ruby
|
|
176
|
+
# programs: classes, modules, methods, and so on.
|
|
177
|
+
autoload :CodeObject, 'rdoc/code_object'
|
|
178
|
+
|
|
179
|
+
autoload :Context, 'rdoc/context'
|
|
180
|
+
autoload :TopLevel, 'rdoc/top_level'
|
|
181
|
+
|
|
182
|
+
autoload :AnonClass, 'rdoc/anon_class'
|
|
183
|
+
autoload :ClassModule, 'rdoc/class_module'
|
|
184
|
+
autoload :NormalClass, 'rdoc/normal_class'
|
|
185
|
+
autoload :NormalModule, 'rdoc/normal_module'
|
|
186
|
+
autoload :SingleClass, 'rdoc/single_class'
|
|
187
|
+
|
|
188
|
+
autoload :Alias, 'rdoc/alias'
|
|
189
|
+
autoload :AnyMethod, 'rdoc/any_method'
|
|
190
|
+
autoload :MethodAttr, 'rdoc/method_attr'
|
|
191
|
+
autoload :GhostMethod, 'rdoc/ghost_method'
|
|
192
|
+
autoload :MetaMethod, 'rdoc/meta_method'
|
|
193
|
+
autoload :Attr, 'rdoc/attr'
|
|
194
|
+
|
|
195
|
+
autoload :Constant, 'rdoc/constant'
|
|
196
|
+
autoload :Mixin, 'rdoc/mixin'
|
|
197
|
+
autoload :Include, 'rdoc/include'
|
|
198
|
+
autoload :Extend, 'rdoc/extend'
|
|
199
|
+
autoload :Require, 'rdoc/require'
|
|
200
|
+
|
|
201
|
+
end
|
data/man/ri.1
ADDED
|
@@ -0,0 +1,247 @@
|
|
|
1
|
+
.\"Ruby is copyrighted by Yukihiro Matsumoto <matz@netlab.jp>.
|
|
2
|
+
.Dd April 20, 2017
|
|
3
|
+
.Dt RI \&1 "Ruby Programmer's Reference Guide"
|
|
4
|
+
.Os UNIX
|
|
5
|
+
.Sh NAME
|
|
6
|
+
.Nm ri
|
|
7
|
+
.Nd Ruby API reference front end
|
|
8
|
+
.Sh SYNOPSIS
|
|
9
|
+
.Nm
|
|
10
|
+
.Op Fl ahilTv
|
|
11
|
+
.Op Fl d Ar DIRNAME
|
|
12
|
+
.Op Fl f Ar FORMAT
|
|
13
|
+
.Op Fl w Ar WIDTH
|
|
14
|
+
.Op Fl - Ns Oo Cm no- Oc Ns Cm pager
|
|
15
|
+
.Op Fl -server Ns Oo = Ns Ar PORT Oc
|
|
16
|
+
.Op Fl - Ns Oo Cm no- Oc Ns Cm list-doc-dirs
|
|
17
|
+
.Op Fl -no-standard-docs
|
|
18
|
+
.Op Fl - Ns Oo Cm no- Oc Ns Bro Cm system Ns | Ns Cm site Ns | Ns Cm gems Ns | Ns Cm home Brc
|
|
19
|
+
.Op Fl - Ns Oo Cm no- Oc Ns Cm profile
|
|
20
|
+
.Op Fl -dump Ns = Ns Ar CACHE
|
|
21
|
+
.Op Ar name ...
|
|
22
|
+
.Sh DESCRIPTION
|
|
23
|
+
.Nm
|
|
24
|
+
is a command-line front end for the Ruby API reference.
|
|
25
|
+
You can search and read the API reference for classes and methods with
|
|
26
|
+
.Nm .
|
|
27
|
+
.Pp
|
|
28
|
+
.Nm
|
|
29
|
+
is a part of Ruby.
|
|
30
|
+
.Pp
|
|
31
|
+
.Ar name
|
|
32
|
+
can be:
|
|
33
|
+
.Bl -diag -offset indent
|
|
34
|
+
.It Class | Module | Module::Class
|
|
35
|
+
.Pp
|
|
36
|
+
.It Class::method | Class#method | Class.method | method
|
|
37
|
+
.Pp
|
|
38
|
+
.It gem_name: | gem_name:README | gem_name:History
|
|
39
|
+
.El
|
|
40
|
+
.Pp
|
|
41
|
+
All class names may be abbreviated to their minimum unambiguous form.
|
|
42
|
+
If a name is ambiguous, all valid options will be listed.
|
|
43
|
+
.Pp
|
|
44
|
+
A
|
|
45
|
+
.Ql \&.
|
|
46
|
+
matches either class or instance methods, while #method
|
|
47
|
+
matches only instance and ::method matches only class methods.
|
|
48
|
+
.Pp
|
|
49
|
+
README and other files may be displayed by prefixing them with the gem name
|
|
50
|
+
they're contained in. If the gem name is followed by a
|
|
51
|
+
.Ql \&:
|
|
52
|
+
all files in the gem will be shown.
|
|
53
|
+
The file name extension may be omitted where it is unambiguous.
|
|
54
|
+
.Pp
|
|
55
|
+
For example:
|
|
56
|
+
.Bd -literal -offset indent
|
|
57
|
+
ri Fil
|
|
58
|
+
ri File
|
|
59
|
+
ri File.new
|
|
60
|
+
ri zip
|
|
61
|
+
ri rdoc:README
|
|
62
|
+
.Ed
|
|
63
|
+
.Pp
|
|
64
|
+
Note that shell quoting or escaping may be required for method names
|
|
65
|
+
containing punctuation:
|
|
66
|
+
.Bd -literal -offset indent
|
|
67
|
+
ri 'Array.[]'
|
|
68
|
+
ri compact\e!
|
|
69
|
+
.Ed
|
|
70
|
+
.Pp
|
|
71
|
+
To see the default directories
|
|
72
|
+
.Nm
|
|
73
|
+
will search, run:
|
|
74
|
+
.Bd -literal -offset indent
|
|
75
|
+
ri --list-doc-dirs
|
|
76
|
+
.Ed
|
|
77
|
+
.Pp
|
|
78
|
+
Specifying the
|
|
79
|
+
.Fl -system , Fl -site , Fl -home , Fl -gems ,
|
|
80
|
+
or
|
|
81
|
+
.Fl -doc-dir
|
|
82
|
+
options will limit
|
|
83
|
+
.Nm
|
|
84
|
+
to searching only the specified directories.
|
|
85
|
+
.Pp
|
|
86
|
+
.Nm
|
|
87
|
+
options may be set in the
|
|
88
|
+
.Ev RI
|
|
89
|
+
environment variable.
|
|
90
|
+
.Pp
|
|
91
|
+
The
|
|
92
|
+
.Nm
|
|
93
|
+
pager can be set with the
|
|
94
|
+
.Ev RI_PAGER
|
|
95
|
+
environment variable or the
|
|
96
|
+
.Ev PAGER
|
|
97
|
+
environment variable.
|
|
98
|
+
.Pp
|
|
99
|
+
.Sh OPTIONS
|
|
100
|
+
.Bl -tag -width "1234567890123" -compact
|
|
101
|
+
.Pp
|
|
102
|
+
.It Fl i
|
|
103
|
+
.It Fl - Ns Oo Cm no- Oc Ns Cm interactive
|
|
104
|
+
In interactive mode you can repeatedly
|
|
105
|
+
look up methods with autocomplete.
|
|
106
|
+
.Pp
|
|
107
|
+
.It Fl a
|
|
108
|
+
.It Fl - Ns Oo Cm no- Oc Ns Cm all
|
|
109
|
+
Show all documentation for a class or module.
|
|
110
|
+
.Pp
|
|
111
|
+
.It Fl l
|
|
112
|
+
.It Fl - Ns Oo Cm no- Oc Ns Cm list
|
|
113
|
+
List classes
|
|
114
|
+
.Nm
|
|
115
|
+
knows about.
|
|
116
|
+
.Pp
|
|
117
|
+
.It Fl - Ns Oo Cm no- Oc Ns Cm pager
|
|
118
|
+
Send output to a pager,
|
|
119
|
+
rather than directly to stdout.
|
|
120
|
+
.Pp
|
|
121
|
+
.It Fl T
|
|
122
|
+
Synonym for
|
|
123
|
+
.Fl -no-pager .
|
|
124
|
+
.Pp
|
|
125
|
+
.It Fl w Ar WIDTH
|
|
126
|
+
.It Fl -width Ns = Ns Ar WIDTH
|
|
127
|
+
Set the width of the output.
|
|
128
|
+
.Pp
|
|
129
|
+
.It Fl -server Ns Oo = Ns Ar PORT Oc
|
|
130
|
+
Run RDoc server on the given port.
|
|
131
|
+
The default port is\~8214.
|
|
132
|
+
.Pp
|
|
133
|
+
.It Fl f Ar FORMAT
|
|
134
|
+
.It Fl -format Ns = Ns Ar FORMAT
|
|
135
|
+
Use the selected formatter.
|
|
136
|
+
The default formatter is
|
|
137
|
+
.Li bs
|
|
138
|
+
for paged output and
|
|
139
|
+
.Li ansi
|
|
140
|
+
otherwise.
|
|
141
|
+
Valid formatters are:
|
|
142
|
+
.Li ansi , Li bs , Li markdown , Li rdoc .
|
|
143
|
+
.Pp
|
|
144
|
+
.It Fl h
|
|
145
|
+
.It Fl -help
|
|
146
|
+
Show help and exit.
|
|
147
|
+
.Pp
|
|
148
|
+
.It Fl v
|
|
149
|
+
.It Fl -version
|
|
150
|
+
Output version information and exit.
|
|
151
|
+
.El
|
|
152
|
+
.Pp
|
|
153
|
+
Data source options:
|
|
154
|
+
.Bl -tag -width "1234567890123" -compact
|
|
155
|
+
.Pp
|
|
156
|
+
.It Fl - Ns Oo Cm no- Oc Ns Cm list-doc-dirs
|
|
157
|
+
List the directories from which
|
|
158
|
+
.Nm
|
|
159
|
+
will source documentation on stdout and exit.
|
|
160
|
+
.Pp
|
|
161
|
+
.It Fl d Ar DIRNAME
|
|
162
|
+
.It Fl -doc-dir Ns = Ns Ar DIRNAME
|
|
163
|
+
List of directories from which to source
|
|
164
|
+
documentation in addition to the standard
|
|
165
|
+
directories. May be repeated.
|
|
166
|
+
.Pp
|
|
167
|
+
.It Fl -no-standard-docs
|
|
168
|
+
Do not include documentation from the Ruby standard library,
|
|
169
|
+
.Pa site_lib ,
|
|
170
|
+
installed gems, or
|
|
171
|
+
.Pa ~/.rdoc .
|
|
172
|
+
Use with
|
|
173
|
+
.Fl -doc-dir .
|
|
174
|
+
.Pp
|
|
175
|
+
.It Fl - Ns Oo Cm no- Oc Ns Cm system
|
|
176
|
+
Include documentation from Ruby's standard library. Defaults to true.
|
|
177
|
+
.Pp
|
|
178
|
+
.It Fl - Ns Oo Cm no- Oc Ns Cm site
|
|
179
|
+
Include documentation from libraries installed in
|
|
180
|
+
.Pa site_lib .
|
|
181
|
+
Defaults to true.
|
|
182
|
+
.Pp
|
|
183
|
+
.It Fl - Ns Oo Cm no- Oc Ns Cm gems
|
|
184
|
+
Include documentation from RubyGems. Defaults to true.
|
|
185
|
+
.Pp
|
|
186
|
+
.It Fl - Ns Oo Cm no- Oc Ns Cm home
|
|
187
|
+
Include documentation stored in
|
|
188
|
+
.Pa ~/.rdoc .
|
|
189
|
+
Defaults to true.
|
|
190
|
+
.El
|
|
191
|
+
.Pp
|
|
192
|
+
Debug options:
|
|
193
|
+
.Bl -tag -width "1234567890123" -compact
|
|
194
|
+
.Pp
|
|
195
|
+
.It Fl - Ns Oo Cm no- Oc Ns Cm profile
|
|
196
|
+
Run with the Ruby profiler.
|
|
197
|
+
.Pp
|
|
198
|
+
.It Fl -dump Ns = Ns Ar CACHE
|
|
199
|
+
Dump data from an ri cache or data file.
|
|
200
|
+
.El
|
|
201
|
+
.Pp
|
|
202
|
+
.Sh ENVIRONMENT
|
|
203
|
+
.Bl -tag -width "USERPROFILE" -compact
|
|
204
|
+
.Pp
|
|
205
|
+
.It Ev RI
|
|
206
|
+
Options to prepend to those specified on the command-line.
|
|
207
|
+
.Pp
|
|
208
|
+
.It Ev RI_PAGER
|
|
209
|
+
.It Ev PAGER
|
|
210
|
+
Pager program to use for displaying.
|
|
211
|
+
.Pp
|
|
212
|
+
.It Ev HOME
|
|
213
|
+
.It Ev USERPROFILE
|
|
214
|
+
.It Ev HOMEPATH
|
|
215
|
+
Path to the user's home directory.
|
|
216
|
+
.El
|
|
217
|
+
.Pp
|
|
218
|
+
.Sh FILES
|
|
219
|
+
.Bl -tag -width "USERPROFILE" -compact
|
|
220
|
+
.Pp
|
|
221
|
+
.It Pa ~/.rdoc
|
|
222
|
+
Path for ri data in the user's home directory.
|
|
223
|
+
.Pp
|
|
224
|
+
.El
|
|
225
|
+
.Pp
|
|
226
|
+
.Sh SEE ALSO
|
|
227
|
+
.Xr ruby 1 ,
|
|
228
|
+
.Xr rdoc 1 ,
|
|
229
|
+
.Xr gem 1
|
|
230
|
+
.Pp
|
|
231
|
+
.Sh REPORTING BUGS
|
|
232
|
+
.Bl -bullet
|
|
233
|
+
.It
|
|
234
|
+
Security vulnerabilities should be reported via an email to
|
|
235
|
+
.Mt security@ruby-lang.org .
|
|
236
|
+
Reported problems will be published after being fixed.
|
|
237
|
+
.Pp
|
|
238
|
+
.It
|
|
239
|
+
Other bugs and feature requests can be reported via the
|
|
240
|
+
Ruby Issue Tracking System
|
|
241
|
+
.Pq Lk https://bugs.ruby-lang.org/ .
|
|
242
|
+
Do not report security vulnerabilities
|
|
243
|
+
via this system because it publishes the vulnerabilities immediately.
|
|
244
|
+
.El
|
|
245
|
+
.Sh AUTHORS
|
|
246
|
+
Written by
|
|
247
|
+
.An Dave Thomas Aq dave@pragmaticprogrammer.com .
|