Dist::Zilla::Plugin::InsertCommandOutput - Insert the output of command into your POD
This document describes version 0.055 of Dist::Zilla::Plugin::InsertCommandOutput (from Perl distribution Dist-Zilla-Plugin-InsertCommandOutput), released on 2021-06-07.
In dist.ini:
[InsertCommandOutput] ;make_verbatim=1
In your POD:
# COMMAND: netstat -anp
This module finds # COMMAND: ... directives in your POD, pass it to the Perl's backtick operator, and insert the result into your POD as a verbatim paragraph (unless if you set make_verbatim to 0, in which case output will be inserted as-is). If command fails ($? is non-zero), build will be aborted.
# COMMAND: ...
make_verbatim
$?
perlancar (@netbook-zenbook) <perlancar@gmail.com>
Please visit the project's homepage at https://metacpan.org/release/Dist-Zilla-Plugin-InsertCommandOutput.
Source repository is at https://github.com/perlancar/perl-Dist-Zilla-Plugin-InsertCommandOutput.
Please report any bugs or feature requests on the bugtracker website https://rt.cpan.org/Public/Dist/Display.html?Name=Dist-Zilla-Plugin-InsertCommandOutput
When submitting a bug or request, please include a test-file or a patch to an existing test-file that illustrates the bug or desired feature.
Dist::Zilla::Plugin::InsertCodeResult, which can also be used to accomplish the same thing, e.g. with # CODE: my $res = `netstat -anp`; die if $?; $res except the DZP::InstallCommandResult plugin is shorter.
# CODE: my $res = `netstat -anp`; die if $?; $res
Dist::Zilla::Plugin::InsertCodeOutput, which can also be used to accomplish the same thing, e.g. with # CODE: system "netstat -anp"; die if $?.
# CODE: system "netstat -anp"; die if $?
Dist::Zilla::Plugin::InsertExample
perlancar <perlancar@cpan.org>
This software is copyright (c) 2021, 2019, 2018, 2015, 2014 by perlancar@cpan.org.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Dist::Zilla::Plugin::InsertCommandOutput, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Dist::Zilla::Plugin::InsertCommandOutput
CPAN shell
perl -MCPAN -e shell install Dist::Zilla::Plugin::InsertCommandOutput
For more information on module installation, please visit the detailed CPAN module installation guide.