{
    "content": [
        {
            "type": "text",
            "text": "# ri (man)\n\n## NAME\n\nri — Ruby API reference front end\n\n## SYNOPSIS\n\nri [-ahilTv] [-d DIRNAME] [-f FORMAT] [-w WIDTH] [--[no-]pager] [--server[=PORT]]\n[--[no-]list-doc-dirs] [--no-standard-docs] [--[no-]{system|site|gems|home}]\n[--[no-]profile] [--dump=CACHE] [name ...]\n\n## DESCRIPTION\n\nri is a command-line front end for the Ruby API reference.  You can search and read the API\nreference for classes and methods with ri.\n\n## TLDR\n\n> Browse structured API documentation for Ruby.\n\n- Start interactive shell:\n  `ri`\n- View documentation for a particular name:\n  `ri {{File#read}}`\n- List classes and modules for which `ri` has documentation:\n  `ri {{-l|--list}}`\n\n*Source: tldr-pages*\n\n## Sections\n\n- **NAME**\n- **SYNOPSIS**\n- **DESCRIPTION**\n- **OPTIONS** (10 subsections)\n- **ENVIRONMENT**\n- **FILES**\n- **SEE ALSO**\n- **REPORTING BUGS**\n- **AUTHORS**\n\nUse structuredContent.sections for detailed options, examples, and full documentation.\n"
        }
    ],
    "structuredContent": {
        "command": "ri",
        "section": "",
        "mode": "man",
        "summary": "ri — Ruby API reference front end",
        "synopsis": "ri [-ahilTv] [-d DIRNAME] [-f FORMAT] [-w WIDTH] [--[no-]pager] [--server[=PORT]]\n[--[no-]list-doc-dirs] [--no-standard-docs] [--[no-]{system|site|gems|home}]\n[--[no-]profile] [--dump=CACHE] [name ...]",
        "tldr_summary": "Browse structured API documentation for Ruby.",
        "tldr_examples": [
            {
                "description": "Start interactive shell",
                "command": "ri"
            },
            {
                "description": "View documentation for a particular name",
                "command": "ri {{File#read}}"
            },
            {
                "description": "List classes and modules for which `ri` has documentation",
                "command": "ri {{-l|--list}}"
            }
        ],
        "tldr_source": "official",
        "flags": [
            {
                "flag": "-i",
                "long": null,
                "arg": null,
                "description": "--[no-]interactive In interactive mode you can repeatedly look up methods with autocomplete."
            },
            {
                "flag": "-a",
                "long": null,
                "arg": null,
                "description": "--[no-]all Show all documentation for a class or module."
            },
            {
                "flag": "-l",
                "long": null,
                "arg": null,
                "description": "--[no-]list List classes ri knows about. --[no-]pager Send output to a pager, rather than directly to stdout."
            },
            {
                "flag": "-T",
                "long": "--no-pager",
                "arg": null,
                "description": ""
            },
            {
                "flag": "-w",
                "long": null,
                "arg": null,
                "description": "--width=WIDTH Set the width of the output. --server[=PORT] Run RDoc server on the given port. The default port is 8214."
            },
            {
                "flag": "-f",
                "long": null,
                "arg": null,
                "description": "--format=FORMAT Use the selected formatter. The default formatter is bs for paged output and ansi otherwise. Valid formatters are: ansi, bs, markdown, rdoc."
            },
            {
                "flag": "-h",
                "long": null,
                "arg": null,
                "description": "--help Show help and exit."
            },
            {
                "flag": "-v",
                "long": null,
                "arg": null,
                "description": "--version Output version information and exit. Data source options: --[no-]list-doc-dirs List the directories from which ri will source documentation on stdout and exit."
            },
            {
                "flag": "-d",
                "long": null,
                "arg": null,
                "description": "--doc-dir=DIRNAME List of directories from which to source documentation in addition to the stan‐ dard directories. May be repeated."
            },
            {
                "flag": "",
                "long": "--no-standard-docs",
                "arg": null,
                "description": "Do not include documentation from the Ruby standard library, sitelib, installed gems, or ~/.rdoc. Use with --doc-dir. --[no-]system Include documentation from Ruby's standard library. Defaults to true. --[no-]site Include documentation from libraries installed in sitelib. Defaults to true. --[no-]gems Include documentation from RubyGems. Defaults to true. --[no-]home Include documentation stored in ~/.rdoc. Defaults to true. Debug options: --[no-]profile Run with the Ruby profiler. --dump=CACHE Dump data from an ri cache or data file."
            }
        ],
        "examples": [],
        "see_also": [
            {
                "name": "ruby",
                "section": "1",
                "url": "https://www.chedong.com/phpMan.php/man/ruby/1/json"
            },
            {
                "name": "rdoc",
                "section": "1",
                "url": "https://www.chedong.com/phpMan.php/man/rdoc/1/json"
            },
            {
                "name": "gem",
                "section": "1",
                "url": "https://www.chedong.com/phpMan.php/man/gem/1/json"
            }
        ],
        "section_outline": [
            {
                "name": "NAME",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "SYNOPSIS",
                "lines": 4,
                "subsections": []
            },
            {
                "name": "DESCRIPTION",
                "lines": 48,
                "subsections": []
            },
            {
                "name": "OPTIONS",
                "lines": 1,
                "subsections": [
                    {
                        "name": "-i",
                        "lines": 3,
                        "flag": "-i"
                    },
                    {
                        "name": "-a",
                        "lines": 2,
                        "flag": "-a"
                    },
                    {
                        "name": "-l",
                        "lines": 4,
                        "flag": "-l"
                    },
                    {
                        "name": "-T --no-pager",
                        "lines": 1,
                        "flag": "-T",
                        "long": "--no-pager"
                    },
                    {
                        "name": "-w",
                        "lines": 5,
                        "flag": "-w"
                    },
                    {
                        "name": "-f",
                        "lines": 4,
                        "flag": "-f"
                    },
                    {
                        "name": "-h",
                        "lines": 2,
                        "flag": "-h"
                    },
                    {
                        "name": "-v",
                        "lines": 7,
                        "flag": "-v"
                    },
                    {
                        "name": "-d",
                        "lines": 4,
                        "flag": "-d"
                    },
                    {
                        "name": "--no-standard-docs",
                        "lines": 18,
                        "long": "--no-standard-docs"
                    }
                ]
            },
            {
                "name": "ENVIRONMENT",
                "lines": 9,
                "subsections": []
            },
            {
                "name": "FILES",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "SEE ALSO",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "REPORTING BUGS",
                "lines": 7,
                "subsections": []
            },
            {
                "name": "AUTHORS",
                "lines": 3,
                "subsections": []
            }
        ],
        "sections": {
            "NAME": {
                "content": "ri — Ruby API reference front end\n",
                "subsections": []
            },
            "SYNOPSIS": {
                "content": "ri [-ahilTv] [-d DIRNAME] [-f FORMAT] [-w WIDTH] [--[no-]pager] [--server[=PORT]]\n[--[no-]list-doc-dirs] [--no-standard-docs] [--[no-]{system|site|gems|home}]\n[--[no-]profile] [--dump=CACHE] [name ...]\n",
                "subsections": []
            },
            "DESCRIPTION": {
                "content": "ri is a command-line front end for the Ruby API reference.  You can search and read the API\nreference for classes and methods with ri.\n\nri is a part of Ruby.\n\nname can be:\n\nClass | Module | Module::Class\n\nClass::method | Class#method | Class.method | method\n\ngemname: | gemname:README | gemname:History\n\nAll class names may be abbreviated to their minimum unambiguous form.  If a name is ambiguous,\nall valid options will be listed.\n\nA ‘.’ matches either class or instance methods, while #method matches only instance and\n::method matches only class methods.\n\nREADME and other files may be displayed by prefixing them with the gem name they're contained\nin.  If the gem name is followed by a ‘:’ all files in the gem will be shown.  The file name\nextension may be omitted where it is unambiguous.\n\nFor example:\n\nri Fil\nri File\nri File.new\nri zip\nri rdoc:README\n\nNote that shell quoting or escaping may be required for method names containing punctuation:\n\nri 'Array.[]'\nri compact\\!\n\nTo see the default directories ri will search, run:\n\nri --list-doc-dirs\n\nSpecifying the --system, --site, --home, --gems, or --doc-dir options will limit ri to search‐\ning only the specified directories.\n\nri options may be set in the RI environment variable.\n\nThe ri pager can be set with the RIPAGER environment variable or the PAGER environment vari‐\nable.\n",
                "subsections": []
            },
            "OPTIONS": {
                "content": "",
                "subsections": [
                    {
                        "name": "-i",
                        "content": "--[no-]interactive\nIn interactive mode you can repeatedly look up methods with autocomplete.\n",
                        "flag": "-i"
                    },
                    {
                        "name": "-a",
                        "content": "--[no-]all     Show all documentation for a class or module.\n",
                        "flag": "-a"
                    },
                    {
                        "name": "-l",
                        "content": "--[no-]list    List classes ri knows about.\n\n--[no-]pager   Send output to a pager, rather than directly to stdout.\n",
                        "flag": "-l"
                    },
                    {
                        "name": "-T --no-pager",
                        "content": "",
                        "flag": "-T",
                        "long": "--no-pager"
                    },
                    {
                        "name": "-w",
                        "content": "--width=WIDTH  Set the width of the output.\n\n--server[=PORT]\nRun RDoc server on the given port.  The default port is 8214.\n",
                        "flag": "-w"
                    },
                    {
                        "name": "-f",
                        "content": "--format=FORMAT\nUse the selected formatter.  The default formatter is bs for paged output and\nansi otherwise.  Valid formatters are: ansi, bs, markdown, rdoc.\n",
                        "flag": "-f"
                    },
                    {
                        "name": "-h",
                        "content": "--help         Show help and exit.\n",
                        "flag": "-h"
                    },
                    {
                        "name": "-v",
                        "content": "--version      Output version information and exit.\n\nData source options:\n\n--[no-]list-doc-dirs\nList the directories from which ri will source documentation on stdout and exit.\n",
                        "flag": "-v"
                    },
                    {
                        "name": "-d",
                        "content": "--doc-dir=DIRNAME\nList of directories from which to source documentation in addition to the stan‐\ndard directories.  May be repeated.\n",
                        "flag": "-d"
                    },
                    {
                        "name": "--no-standard-docs",
                        "content": "Do not include documentation from the Ruby standard library, sitelib, installed\ngems, or ~/.rdoc.  Use with --doc-dir.\n\n--[no-]system  Include documentation from Ruby's standard library.  Defaults to true.\n\n--[no-]site    Include documentation from libraries installed in sitelib.  Defaults to true.\n\n--[no-]gems    Include documentation from RubyGems.  Defaults to true.\n\n--[no-]home    Include documentation stored in ~/.rdoc.  Defaults to true.\n\nDebug options:\n\n--[no-]profile\nRun with the Ruby profiler.\n\n--dump=CACHE   Dump data from an ri cache or data file.\n",
                        "long": "--no-standard-docs"
                    }
                ]
            },
            "ENVIRONMENT": {
                "content": "RI           Options to prepend to those specified on the command-line.\n\nRIPAGER\nPAGER        Pager program to use for displaying.\n\nHOME\nUSERPROFILE\nHOMEPATH     Path to the user's home directory.\n",
                "subsections": []
            },
            "FILES": {
                "content": "~/.rdoc      Path for ri data in the user's home directory.\n",
                "subsections": []
            },
            "SEE ALSO": {
                "content": "ruby(1), rdoc(1), gem(1)\n",
                "subsections": []
            },
            "REPORTING BUGS": {
                "content": "••   Security vulnerabilities should be reported via an email to security@ruby-lang.org.  Re‐\nported problems will be published after being fixed.\n\n••   Other bugs and feature requests can be reported via the Ruby Issue Tracking System\n(https://bugs.ruby-lang.org/). Do not report security vulnerabilities via this system be‐\ncause it publishes the vulnerabilities immediately.\n",
                "subsections": []
            },
            "AUTHORS": {
                "content": "Written by Dave Thomas <dave@pragmaticprogrammer.com>.\n\nUNIX                            April 20, 2017                            UNIX",
                "subsections": []
            }
        }
    }
}