Generally, the rdoc command is used for RubyProgramGenerate document
Eg:
Rdoc test. Rb
To generate a document for the RB file of the entire project, you only need to run the rdoc command without the file name.
Eg:
Rdoc
If there are classes and methods that do not want to generate Doc
Eg:
Def no_doc #: nodoc:
End
Or
Class nodocclass #: nodoc: All
Some comments do not want to generate Doc
#--
# This row does not generate Doc
# ++
# This row generates the doc
Rdoc command:
-- All: by default, only common methods are generated for rdoc. Using -- all, all methods are generated for Doc.
-- FMT <XML, yaml, CHM, pdf>: generate a document in the specified format
-- Help:
-- Inline-Source: SetCodeShow in document
-- Main <Name>: Set the name of the primary index page.
-- One-file: put all the content of rdoc in one file.
-- Op <Directory Name>: Specifies the Directory Name of the output directory.