Class Index
- WebRI
- WebRI::Blackfish
- WebRI::Component
- WebRI::Generator
- WebRI::GeneratorOne
- WebRI::GitHub
- WebRI::Heirarchy
- WebRI::Highlight
- WebRI::Icons
- WebRI::JSONFile
- WebRI::Longfish
- WebRI::Metadata
- WebRI::Newfish
- WebRI::Oldfish
- WebRI::Onefish
- WebRI::Prettify
- WebRI::Redfish
- WebRI::RiService
- WebRI::Search
- WebRI::Search::FilesTree
- WebRI::Server
- WebRI::Subversion
- WebRI::Template
- WebRI::TimeDelta
- WebRI::Twofish
- RDoc
- RDoc::AnyMethod
- RDoc::ClassModule
- RDoc::Options
- RDoc::Parser
- RDoc::Parser::C
- RDoc::TopLevel
- Syckle
- Syckle::Plugins
- Syckle::Plugins::WebRI
- Object
- OpEsc
Method Index
- WebRI::Generator ::components
- WebRI ::entry_to_path
- WebRI::Server ::esc
- OpEsc ::escape
- WebRI::Generator ::for
- WebRI::Generator ::include
- WebRI::Generator ::inherited
- WebRI::Heirarchy ::new
- WebRI::Server ::new
- WebRI::RiService ::new
- WebRI::Generator ::new
- WebRI::GeneratorOne ::new
- WebRI::Template ::new
- WebRI::Component ::new
- WebRI::Generator ::new
- WebRI ::path_to_entry
- OpEsc ::unescape
- WebRI::Heirarchy #[]
- WebRI::Heirarchy #[]=
- WebRI::Search::FilesTree #add
- WebRI::Search #add_class_search_index
- WebRI::Search #add_file_search_index
- WebRI::Search #add_method_search_index
- WebRI::JSONFile #all_methods
- WebRI::GeneratorOne #asset
- WebRI::Server #autolink
- WebRI::Template #class_dir
- WebRI::Generator #class_dir
- WebRI::JSONFile #class_tree
- WebRI::Template #classes
- WebRI::Generator #classes
- WebRI::JSONFile #classes
- WebRI::Generator #classes_hash
- WebRI::Template #classes_hash
- WebRI::Generator #classes_salient
- WebRI::Template #classes_salient
- WebRI::Generator #classes_toplevel
- WebRI::Template #classes_toplevel
- Syckle::Plugins::WebRI #clean
- WebRI::GitHub #commit_sha1
- WebRI::Template #copyright
- WebRI::Generator #copyright
- WebRI::GeneratorOne #css
- WebRI::Server #current_content
- WebRI::GeneratorOne #current_content
- WebRI::Generator #current_content
- WebRI::Generator #debug_msg
- WebRI::Component #debug_msg
- WebRI::Server #directory
- Syckle::Plugins::WebRI #document
- RDoc::ClassModule #document_self_or_methods
- WebRI::Blackfish #each_letter_group
- WebRI::Generator #erb_template
- WebRI::Server #esc
- WebRI::Generator #eval_template
- WebRI::Template #file_dir
- WebRI::Generator #file_dir
- WebRI::Heirarchy #file_name
- WebRI::JSONFile #file_tree
- WebRI::Generator #files
- WebRI::Template #files
- WebRI::JSONFile #files
- WebRI::Generator #files_hash
- WebRI::Template #files_hash
- WebRI::Generator #files_toplevel
- WebRI::Template #files_toplevel
- Object #fileutils
- RDoc::Parser::C #find_class_comment
- RDoc::Parser::C #find_class_comment
- WebRI::Template #find_class_named
- WebRI::Generator #find_class_named
- WebRI::Generator #find_file_named
- WebRI::Template #find_file_named
- WebRI::Generator #find_module_named
- WebRI::Template #find_module_named
- WebRI::Generator #find_type_named
- WebRI::Template #find_type_named
- WebRI::Heirarchy #full_name
- WebRI::Generator #generate
- WebRI::Search #generate
- WebRI::JSONFile #generate
- WebRI::Generator #generate
- WebRI::GeneratorOne #generate
- WebRI::Component #generate
- WebRI::JSONFile #generate_class_tree
- WebRI::JSONFile #generate_class_tree_level
- WebRI::Onefish #generate_classes
- WebRI::Generator #generate_classes
- WebRI::Generator #generate_commons
- WebRI::Generator #generate_components
- WebRI::Search #generate_file_tree
- WebRI::JSONFile #generate_file_tree
- WebRI::JSONFile #generate_file_tree_level
- WebRI::Search #generate_file_tree_level
- WebRI::Generator #generate_files
- WebRI::Onefish #generate_files
- WebRI::Twofish #generate_html_tree
- WebRI::Generator #generate_index
- WebRI::Generator #generate_recurse
- WebRI::GeneratorOne #generate_recurse
- WebRI::Search #generate_search_index
- WebRI::Search #generate_search_tree
- WebRI::Search #generate_search_tree_level
- WebRI::Generator #generate_setup
- WebRI::Component #generate_static
- WebRI::Generator #generate_static
- WebRI::GeneratorOne #generate_support_files
- WebRI::Generator #generate_support_files
- WebRI::Generator #generate_template
- WebRI::Server #generate_tree
- WebRI::Metadata #get_metadata
- WebRI::Subversion #get_svninfo
- WebRI::GitHub #github_url
- WebRI::GitHub #github_url_cache
- WebRI::Blackfish #group_name
- WebRI::Server #heirarchy
- WebRI::Twofish #html_tree
- WebRI::GitHub #in_dir
- WebRI::Template #include_template
- WebRI::Template #include_template
- WebRI::Server #index
- WebRI::Longfish #index_description
- WebRI::Generator #index_file
- WebRI::Longfish #index_title
- WebRI::RiService #info
- WebRI::Generator #initialize_components
- Syckle::Plugins::WebRI #initialize_defaults
- WebRI::GitHub #initialize_methods
- WebRI::Subversion #initialize_methods
- WebRI::Generator #initialize_methods
- WebRI::Component #initialize_methods
- WebRI::Generator #initialize_template
- WebRI::Heirarchy #inspect
- WebRI::GeneratorOne #jquery
- WebRI::Generator #json_creatable?
- WebRI::Heirarchy #key
- WebRI::Server #lookup
- Syckle::Plugins::WebRI #main_document
- WebRI::Metadata #metadata
- WebRI::Template #method_missing
- WebRI::Component #method_missing
- WebRI::Generator #methods_all
- WebRI::Template #methods_all
- WebRI::Template #modules
- WebRI::Generator #modules
- WebRI::Template #modules_hash
- WebRI::Generator #modules_hash
- WebRI::Template #modules_salient
- WebRI::Generator #modules_salient
- WebRI::Template #modules_toplevel
- WebRI::Generator #modules_toplevel
- WebRI::Component #name
- WebRI::RiService #names
- WebRI::RiService #names_from_all
- WebRI::RiService #names_from_library
- WebRI::Template #options
- RDoc::Options #parse
- WebRI::Longfish #parse_index_header
- WebRI::Search #path
- WebRI::Longfish #path
- WebRI::Subversion #path
- WebRI::Generator #path
- WebRI::Generator #path_output_relative
- WebRI::GitHub #path_relative_to_repository
- WebRI::Component #path_static
- WebRI::Generator #path_static
- WebRI::Generator #path_template
- WebRI::GitHub #path_to_git_dir
- WebRI::Generator #provision
- WebRI::Component #provision
- RDoc::Options #rdoc_parse
- Syckle::Plugins::WebRI #rdoc_target
- WebRI::Server #render
- WebRI::Template #render
- WebRI::Generator #render_template
- WebRI::GitHub #repository_url
- Syckle::Plugins::WebRI #reset
- WebRI::RiService #ri_opts
- WebRI::GeneratorOne #rijquery
- WebRI::Heirarchy #root?
- WebRI::JSONFile #save_data
- WebRI::Metadata #scm
- WebRI::Search #search_string
- WebRI::Longfish #site_community
- WebRI::Longfish #site_homepage
- WebRI::Longfish #site_news
- WebRI::Longfish #site_repository
- WebRI::Search #snippet
- WebRI::Generator #sort_salient
- WebRI::Subversion #svninfo
- WebRI::Server #template
- WebRI::TimeDelta #time_delta_string
- WebRI::Server #title
- WebRI::Template #title
- WebRI::Generator #title
- RDoc::TopLevel #to_h
- RDoc::ClassModule #to_h
- RDoc::AnyMethod #to_h
- RDoc::AnyMethod #to_json
- RDoc::ClassModule #to_json
- RDoc::TopLevel #to_json
- WebRI::Server #tree
- WebRI::Template #types
- WebRI::Generator #types
- WebRI::Generator #types_hash
- WebRI::Template #types_hash
- WebRI::Template #types_salient
- WebRI::Generator #types_salient
- WebRI::Generator #types_toplevel
- WebRI::Template #types_toplevel
- RDoc::ClassModule #with_documentation?
- WebRI::GeneratorOne #write
- WebRI::Generator #write
WebRI
DESCRIPTION
WebRI is both a dynamic web-based ri-browser which can provided ri documentation dynamically, by running a webrick server, and a superalatvie Ruby documentation generator with a variety of built in templates.
FEATURES
- WebRI provides Beautiful Templates, enhanced renditions of some of the best designs currently in use.
- Variety of templates built-in, to meet a varitey of tastes and needs.
- Under the hood, a component system allows geneators to be more easily extended.
LIMITATIONS
Please note that the ri web server and the generation system were developed separately, and are not well integrated. For this reason (at the very least) the ri server cannot use the templates available to the generators. If possible, a future version will allow this.
USAGE SYNOPSIS
Generate Documentation
WebRI provides a webri executable you can use to generate documentation. The interface is identical to rdoc. Use the -T option to specify a template type.
$ webri -T redfish README lib/
You can use rdoc command if you prefer (though in far off future versions this may not be the case).
$ rdoc -T redfish README lib/
WebRI extend RIDoc to recognize the templates that WebRI will handle and transfers control to appropriate WebRI generator accordingly.
Using the Web Server
WebRI can be used as a dynamic ri browser, either for a single project or for a collection of libraries. Indeed, the WebRI server can be used to browse the entire installed object system —eveything documented in your central install locations. To do the later, simply execute webri-server with no arguments and open a webrowser to the local port designated (see below).
$ webr-server
To browse per-project ri documentation, you will first need to locate the project’s ri files, either by locating them in your system installation or by generating them for a project, which can be done using rdoc, eg.
$ rdoc --ri --op "doc/ri" lib/
Sometimes a package will include a convenience script for generating these. Try running ‘rake -T’, or look for a ‘script/’ or ‘task/’ executable that does the job. Usually the generated documentation is placed in either ri/ or doc/ri/. I will use doc/ri/ in the following example, adjust your directory as needed.
With ri files loacted you can view them with:
$ webri-server doc/ri
You will see a Webrick server start up, informing you of the port being used.
[2008-03-28 12:11:16] INFO WEBrick 1.3.1 [2008-03-28 12:11:16] INFO ruby 1.8.6 (2007-06-07) [x86_64-linux] [2008-03-28 12:11:21] INFO WEBrick::HTTPServer#start: pid=8870 port=8888
In this example we see the port is the default 8888. Simply open your browser and navigate to:
http://localhost:8888/
On the left side of the screen you will see a navigation tree, and the right side contans an infromation panel.
NOTE: Becuase ri itself isn’t very fast, if you use WebRI against the entire set of installed Ruby libraries it can take a few seconds to load up. (Sure wish FastRI turned out for the better.)
INSTALLATION
Installing via RubyGems is per the usual:
$ sudo gem install webri
COPYING
WebRI Copyright © 2009 Thomas Sawyer, MIT License
THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.