description: > Simple markup language documenting Ruby code.
Document Ruby code using simple comments.
Table of Contents
# = H1
# == H2
And so forth.
# Paragraph
# Still Paragraph
#
# New Paragraph
#
# this.will.be(verbatim)
Inline text modifiers.
Precede first control-char with \
to escape it.
Classes, source files, and method names are linked automatically using plain text
Eg. http:
, mailto:
, ftp:
, and www.
prefixes.
Images are turned into <img>
s automatically.
Use link:asd/asd.html
for links relative to -op
dir.
Labeled links with either one of:
label[url]
{multi word label}[url]
Lists are typed as indented paragraphs with:
# Regular paragraph
# * bullet list
# - bullet list
# 1. numbered list a. alpha list
# A. alpha list
# [cat] small domestic animal
# [+cat+] command to copy standard input
For tabular format:
# cat:: small domestic animal
# indent the second line
# +cat+:: command to copy standard input
# you don't have to indent all the
# way though
# --- or more hyphens
Beginning of method comment call-seq:
.
# call-seq:
# function(arg1,arg2) => result
# function(arg1, arg2, arg3) => res
#
# Begin description
For example,
# rdoc Comment line
#--
# Not a rdoc comment
#++
# rdoc again
Relabel yield arguments.
def fred # :yields: index, position
yield line, address
end
# --------------------------------------
# :section: My Section
# This is the section that I wrote.
# --------------------------------------
For more details read the official documentation{:rel="nofollow noreferrer noopener"}
Original by jan.varwig.org. Licensed under Creative Commons BY-SA.