The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

list-scriptx-plugins - List locally installed ScriptX plugins

VERSION

This document describes version 0.002 of list-scriptx-plugins (from Perl distribution App-ScriptXUtils), released on 2020-10-01.

SYNOPSIS

Usage:

 % list-scriptx-plugins [--detail] [--dist-contains=s] [--dist-in-json=s]
     [--dist-in=s+] [--dist-is=s] [--dist-isnt=s] [--dist-max=s]
     [--dist-min=s] [--dist-not-contains=s] [--dist-not-in-json=s]
     [--dist-not-in=s+] [--dist-xmax=s] [--dist-xmin=s] [--dist=s]
     [--exclude-field=s+] [--exclude-fields-json=s] [--field=s+]
     [--fields-json=s] [--format=name] [--json] [-l] [--(no)naked-res]
     [--no-detail] [--no-random] [--nodetail] [--norandom]
     [--page-result[=program]] [--plugin-contains=s] [--plugin-in-json=s]
     [--plugin-in=s+] [--plugin-is=s] [--plugin-isnt=s] [--plugin-max=s]
     [--plugin-min=s] [--plugin-not-contains=s] [--plugin-not-in-json=s]
     [--plugin-not-in=s+] [--plugin-xmax=s] [--plugin-xmin=s] [--plugin=s]
     [--random] [--result-limit=s] [--result-start=s] [--sort-json=s]
     [--sort=s+] [--summary-contains=s] [--summary-in-json=s]
     [--summary-in=s+] [--summary-is=s] [--summary-isnt=s]
     [--summary-max=s] [--summary-min=s] [--summary-not-contains=s]
     [--summary-not-in-json=s] [--summary-not-in=s+] [--summary-xmax=s]
     [--summary-xmin=s] [--summary=s] [--with-field-names]
     [--without-field-names] [query]

DESCRIPTION

REPLACE ME

OPTIONS

* marks required options.

Field selection options

--detail, -l

Return array of full records instead of just ID fields.

By default, only the key (ID) field is returned per result entry.

--exclude-field=s@

Select fields to return.

Can be specified multiple times.

--exclude-fields-json=s

Select fields to return (JSON-encoded).

See --exclude-field.

--field=s@

Select fields to return.

Can be specified multiple times.

--fields-json=s

Select fields to return (JSON-encoded).

See --field.

--with-field-names

Return field names in each record (as hash/associative array).

When enabled, function will return each record as hash/associative array (field name => value pairs). Otherwise, function will return each record as list/array (field value, field value, ...).

Filtering for dist options

--dist-contains=s

Only return records where the 'dist' field contains specified text.

--dist-in-json=s

Only return records where the 'dist' field is in the specified values (JSON-encoded).

See --dist-in.

--dist-in=s@

Only return records where the 'dist' field is in the specified values.

Can be specified multiple times.

--dist-is=s

Only return records where the 'dist' field equals specified value.

--dist-isnt=s

Only return records where the 'dist' field does not equal specified value.

--dist-max=s

Only return records where the 'dist' field is less than or equal to specified value.

--dist-min=s

Only return records where the 'dist' field is greater than or equal to specified value.

--dist-not-contains=s

Only return records where the 'dist' field does not contain specified text.

--dist-not-in-json=s

Only return records where the 'dist' field is not in the specified values (JSON-encoded).

See --dist-not-in.

--dist-not-in=s@

Only return records where the 'dist' field is not in the specified values.

Can be specified multiple times.

--dist-xmax=s

Only return records where the 'dist' field is less than specified value.

--dist-xmin=s

Only return records where the 'dist' field is greater than specified value.

--dist=s

Only return records where the 'dist' field equals specified value.

Filtering for plugin options

--plugin-contains=s

Only return records where the 'plugin' field contains specified text.

--plugin-in-json=s

Only return records where the 'plugin' field is in the specified values (JSON-encoded).

See --plugin-in.

--plugin-in=s@

Only return records where the 'plugin' field is in the specified values.

Can be specified multiple times.

--plugin-is=s

Only return records where the 'plugin' field equals specified value.

--plugin-isnt=s

Only return records where the 'plugin' field does not equal specified value.

--plugin-max=s

Only return records where the 'plugin' field is less than or equal to specified value.

--plugin-min=s

Only return records where the 'plugin' field is greater than or equal to specified value.

--plugin-not-contains=s

Only return records where the 'plugin' field does not contain specified text.

--plugin-not-in-json=s

Only return records where the 'plugin' field is not in the specified values (JSON-encoded).

See --plugin-not-in.

--plugin-not-in=s@

Only return records where the 'plugin' field is not in the specified values.

Can be specified multiple times.

--plugin-xmax=s

Only return records where the 'plugin' field is less than specified value.

--plugin-xmin=s

Only return records where the 'plugin' field is greater than specified value.

--plugin=s

Only return records where the 'plugin' field equals specified value.

Filtering for summary options

--summary-contains=s

Only return records where the 'summary' field contains specified text.

--summary-in-json=s

Only return records where the 'summary' field is in the specified values (JSON-encoded).

See --summary-in.

--summary-in=s@

Only return records where the 'summary' field is in the specified values.

Can be specified multiple times.

--summary-is=s

Only return records where the 'summary' field equals specified value.

--summary-isnt=s

Only return records where the 'summary' field does not equal specified value.

--summary-max=s

Only return records where the 'summary' field is less than or equal to specified value.

--summary-min=s

Only return records where the 'summary' field is greater than or equal to specified value.

--summary-not-contains=s

Only return records where the 'summary' field does not contain specified text.

--summary-not-in-json=s

Only return records where the 'summary' field is not in the specified values (JSON-encoded).

See --summary-not-in.

--summary-not-in=s@

Only return records where the 'summary' field is not in the specified values.

Can be specified multiple times.

--summary-xmax=s

Only return records where the 'summary' field is less than specified value.

--summary-xmin=s

Only return records where the 'summary' field is greater than specified value.

--summary=s

Only return records where the 'summary' field equals specified value.

Filtering options

--query=s, -q

Search.

Ordering options

--random

Return records in random order.

--sort-json=s

Order records according to certain field(s) (JSON-encoded).

See --sort.

--sort=s@

Order records according to certain field(s).

A list of field names separated by comma. Each field can be prefixed with '-' to specify descending order instead of the default ascending.

Can be specified multiple times.

Output options

--format=s

Choose output format, e.g. json, text.

Default value:

 undef
--json

Set output format to json.

--naked-res

When outputing as JSON, strip result envelope.

Default value:

 0

By default, when outputing as JSON, the full enveloped result is returned, e.g.:

    [200,"OK",[1,2,3],{"func.extra"=>4}]

The reason is so you can get the status (1st element), status message (2nd element) as well as result metadata/extra result (4th element) instead of just the result (3rd element). However, sometimes you want just the result, e.g. when you want to pipe the result for more post-processing. In this case you can use `--naked-res` so you just get:

    [1,2,3]
--page-result

Filter output through a pager.

Paging options

--result-limit=s

Only return a certain number of records.

--result-start=s

Only return starting from the n'th record.

Default value:

 1

Other options

--help, -h, -?

Display help message and exit.

--version, -v

Display program's version and exit.

COMPLETION

This script has shell tab completion capability with support for several shells.

bash

To activate bash completion for this script, put:

 complete -C list-scriptx-plugins list-scriptx-plugins

in your bash startup (e.g. ~/.bashrc). Your next shell session will then recognize tab completion for the command. Or, you can also directly execute the line above in your shell to activate immediately.

It is recommended, however, that you install modules using cpanm-shcompgen which can activate shell completion for scripts immediately.

tcsh

To activate tcsh completion for this script, put:

 complete list-scriptx-plugins 'p/*/`list-scriptx-plugins`/'

in your tcsh startup (e.g. ~/.tcshrc). Your next shell session will then recognize tab completion for the command. Or, you can also directly execute the line above in your shell to activate immediately.

It is also recommended to install shcompgen (see above).

other shells

For fish and zsh, install shcompgen as described above.

HOMEPAGE

Please visit the project's homepage at https://metacpan.org/release/App-ScriptXUtils.

SOURCE

Source repository is at https://github.com/perlancar/perl-App-ScriptXUtils.

BUGS

Please report any bugs or feature requests on the bugtracker website https://rt.cpan.org/Public/Dist/Display.html?Name=App-ScriptXUtils

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.

AUTHOR

perlancar <perlancar@cpan.org>

COPYRIGHT AND LICENSE

This software is copyright (c) 2020, 2019 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.