tools: Add color to perldoc.

- Also showing stdout and stderr in any case.
This commit is contained in:
Andrew Hamilton 2019-09-03 21:15:06 +10:00
parent 23b4f8c931
commit 3a9b4ce361
4 changed files with 46 additions and 44 deletions

View file

@ -387,14 +387,6 @@ def python_mccabe(path):
# Status.not_applicable) # Status.not_applicable)
@deps(deps={"perl-doc"}, url="http://perldoc.perl.org/",
executables={"perldoc"})
def perldoc(path):
stdout, stderr, returncode = _do_command(["perldoc", "-t", path])
return ((Status.normal, stdout) if returncode == 0
else (Status.not_applicable, stderr))
@deps(deps={"perltidy"}, url="http://perltidy.sourceforge.net/", @deps(deps={"perltidy"}, url="http://perltidy.sourceforge.net/",
executables={"perltidy"}) executables={"perltidy"})
def perltidy(path): def perltidy(path):

View file

@ -96,6 +96,14 @@ tools_for_extensions = [
command = "perl6 -c" command = "perl6 -c"
has_color = true has_color = true
[perldoc]
dependencies = ["perl-doc"]
url = "http://perldoc.perl.org/"
command = "perldoc -oterm"
success_status = "normal"
error_status = "not_applicable"
has_color = true
[git_blame] [git_blame]
dependencies = ["git"] dependencies = ["git"]
url = "https://git-scm.com/docs/git-blame" url = "https://git-scm.com/docs/git-blame"

View file

@ -1,61 +1,61 @@
Net::Z3950::AsyncZ Net::Z3950::AsyncZ
Intro Intro
Net::Z3950::AsyncZ adds an additional layer of asynchronous support for Net::Z3950::AsyncZ adds an additional layer of asynchronous support for
the Z3950 module through the use of multiple forked processes. I hope the Z3950 module through the use of multiple forked processes. I hope that
that users will also find that it provides a convenient front end to users will also find that it provides a convenient front end to
"Net::Z3950". My initial idea was to write something that would provide "Net::Z3950". My initial idea was to write something that would provide a
a convenient means of processing and formatting Z39.50 records--which I convenient means of processing and formatting Z39.50 records--which I did,
did, using the "Z3950" synchronous code. But I also wanted something using the "Z3950" synchronous code. But I also wanted something that could
that could handle queries to large numbers of servers at one session. handle queries to large numbers of servers at one session. Working on this
Working on this part of my project, I found that I had trouble with the part of my project, I found that I had trouble with the "Z3950"
"Z3950" asynchronous features and so ended up with what I have here. asynchronous features and so ended up with what I have here.
I give a more detailed account in in the DESCRIPTION section of I give a more detailed account in in the DESCRIPTION section of
"AsyncZ.pod". "AsyncZ.pod".
Documentation Documentation
AsyncZ.pod AsyncZ.pod
This is the starting point--it gives an overview of the AsyncZ This is the starting point--it gives an overview of the AsyncZ module,
module, describes the basic mechanics of its asynchronous workings, describes the basic mechanics of its asynchronous workings, and
and details the particulars of the objects and methods. But see details the particulars of the objects and methods. But see
""Examples.pod" for detailed explanations of the sample scripts ""Examples.pod" for detailed explanations of the sample scripts which
which come with the "Net::Z3950::AsyncZ" distribution. come with the "Net::Z3950::AsyncZ" distribution.
Options.pod Options.pod
This document details the various options that can be set to modify This document details the various options that can be set to modify
the behavior of AsyncZ Index the behavior of AsyncZ Index
Report.pod Report.pod
Report.pod deals with how records are treated line by line and how Report.pod deals with how records are treated line by line and how you
you can affect the apearance of a record's line by line output can affect the apearance of a record's line by line output
Examples.pod Examples.pod
This document goes through the sample scripts that come with the This document goes through the sample scripts that come with the
"Net::Z3950::AsyncZ" distribution and annotates them in a "Net::Z3950::AsyncZ" distribution and annotates them in a line-by-line
line-by-line fashion. It's a basic HOW-TO. fashion. It's a basic HOW-TO.
The Modules The Modules
There are more modules than there is documentation. The reason for this There are more modules than there is documentation. The reason for this is
is that the only module you have full and complete access to is that the only module you have full and complete access to is
"Net::Z3950::AsyncZ". The other modules are either internal to "Net::Z3950::AsyncZ". The other modules are either internal to
"Net::AsyncZ" or accessed indirectly or in part indirectly. "Net::AsyncZ" or accessed indirectly or in part indirectly.
Here are the modules: Here are the modules:
Net::Z3950::AsyncZ Net::Z3950::AsyncZ
The main module: direct access --documented in "AsyncZ" and The main module: direct access --documented in "AsyncZ" and "Options"
"Options" documentation documentation
Net::Z3950::AsyncZ::ErrMsg Net::Z3950::AsyncZ::ErrMsg
User error message handling: indirect access -- documented in User error message handling: indirect access -- documented in "AsyncZ"
"AsyncZ" documentation documentation
Net::Z3950::AsyncZ::Errors Net::Z3950::AsyncZ::Errors
Error handling for debugging: limited access -- documented in Error handling for debugging: limited access -- documented in "AsyncZ"
"AsyncZ" documentation documentation
Net::Z3950::AsyncZ::Report Net::Z3950::AsyncZ::Report
Module reponsible for fetching and formatting records: limited Module reponsible for fetching and formatting records: limited access
access -- documented -- documented
Net::Z3950::AsyncZ::ZLoop Net::Z3950::AsyncZ::ZLoop
Event loop for child processes: no access -- not documented Event loop for child processes: no access -- not documented
@ -64,7 +64,8 @@ Net::Z3950::AsyncZ
Connection details for child processes: no access -- not documented Connection details for child processes: no access -- not documented
Net::Z3950::AsyncZ::Options::_params Net::Z3950::AsyncZ::Options::_params
Options for child processes: direct and indirect access -- Options for child processes: direct and indirect access -- documented
documented in "Options" and "AsyncZ" documentation in "Options" and "AsyncZ" documentation
INDEX INDEX


View file

@ -1 +1,2 @@
No documentation found for "./input/perl.pl". No documentation found for "./input/perl.pl".