This is a WEBrick servlet that allows you to browse ri documentation.
You can show documentation through either ri --server or, with RubyGems 2.0 or newer, gem server. For ri, the server runs on port 8214 by default. For RubyGems the server runs on port 8808 by default.
You can use this servlet in your own project by mounting it on a WEBrick server:
require 'webrick'
server = WEBrick::HTTPServer.new Port: 8000
server.mount '/', RDoc::Servlet
If you want to mount the servlet some other place than the root, provide the base path when mounting:
server.mount '/rdoc', RDoc::Servlet, '/rdoc'
| Use Case | Command | Description |
|---|---|---|
| Start ri server | ri --server |
Starts a WEBrick server on port 8214 to browse ri documentation |
| Start gem server | gem server |
Starts a WEBrick server on port 8808 to browse gem documentation |
| Mount servlet on custom server | server.mount '/', RDoc::Servlet |
Mounts RDoc::Servlet at the root of a custom WEBrick server |
| Mount servlet with custom path | server.mount '/rdoc', RDoc::Servlet, '/rdoc' |
Mounts RDoc::Servlet at a custom path with base path adjustment |
| Access documentation | http://localhost:8000 |
Navigate to the server's URL to view documentation |
newassetasset_dirsdo_GETdocumentation_pagedocumentation_searchdocumentation_sourceerrorgenerator_forif_modified_sinceinstalled_docsnot_foundoptionsri_pathsrootroot_searchshow_documentationstore_forasset_dirs (attr_reader)options (attr_reader)Generated by phpman v4.9.26-1-g511901d · Markdown · JSON · MCP Author: Che Dong Under GNU General Public License
2026-07-29 05:28 @216.73.217.46
CrawledBy Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)
Enhanced by LLM: deepseek-v4-flash / taotoken.net / www.chedong.com - original format