Grinnz / perldoc-browser

Perldoc Browser
https://perldoc.perl.org
Artistic License 2.0
55 stars 21 forks source link

=head1 NAME

Perldoc Browser

=head1 INSTALLATION

Perldoc Browser requires at least Perl v5.20.0 and may have other requirements if you enable a search backend. Perl dependencies are listed in F. To install them, use cpanm:

cpanm --installdeps . # no search dependencies cpanm --installdeps --with-feature=install . # for install command cpanm --installdeps --with-feature=pg . cpanm --installdeps --with-feature=es . cpanm --installdeps --with-feature=sqlite . cpanm --installdeps --with-all-features .

=head1 CONFIGURATION

Perldoc Browser is configured by F in the application directory. The configuration file is a Perl hash. The C key will be used to configure L<Hypnotoad|Mojo::Server::Hypnotoad/"SETTINGS"> if it is used to start the web application.

The search backend can be set using the C key. Recognized values are C, C, C, and C (default: disables the search and indexing).

The C backend requires L and a PostgreSQL server running at least version 9.6. The C configuration key must be set to a database connection URL in the form Cpostgresql://user:password@host:port/database.

The C backend requires L and an Elasticsearch server running at least version 7.0. The C configuration key may be set to the URL to connect to the server (defaults to Chttp://localhost:9200).

The C backend requires L. The database is stored in the application home directory as F by default. This may be configured by setting the C configuration key to a file path, which must be an absolute path to a writable directory.

=head1 PERL MANAGEMENT

Perldoc Browser renders documentation from any Perls it finds installed in the configured C, which defaults to F in the application directory. If no Perls are found here, it will display documentation for the Perl interpreter currently in use. The C command can be used to use L to install one or more Perls to this directory.

./perldoc-browser.pl install 5.10.1 5.28.0

Once a search backend is enabled, Perls must be indexed in this backend for contents of documents and document/function/variable names to be available to the search. The C command will index or reindex the contents and names of one or more Perls.

./perldoc-browser.pl index 5.10.1 5.28.0 ./perldoc-browser.pl index all # reindexes all Perls found in perls_dir

=head1 AUTHOR

Dan Book dbook@cpan.org

PerldocBrowser::Plugin::PerldocRenderer is a fork of the L<Mojolicious|https://mojolicious.org> team's L<PODRenderer plugin|https://search.cpan.org/perldoc?Mojolicious::Plugin::PODRenderer> and its associated template.

=head1 COPYRIGHT AND LICENSE

This software is Copyright (c) 2018 by Dan Book dbook@cpan.org.

PerldocBrowser::Plugin::PerldocRenderer is Copyright (c) 2008-2018 Sebastian Riedel and others, 2018 Dan Book dbook@cpan.org.

This is free software, licensed under:

The Artistic License 2.0 (GPL Compatible)

Bundled Perl 5 Raptor is Copyright (c) 2012, Sebastian Riedel, licensed under the CC-SA License, Version 4.0 Lhttp://creativecommons.org/licenses/by-sa/4.0.

Bundled highlight.pack.js is Copyright (c) 2006 by Ivan Sagalaev, licensed under the (three-clause) BSD License Lhttps://opensource.org/licenses/BSD-3-Clause.