App::Codeowners::Options - Getopt and shell completion for App::Codeowners
version 0.48
$options = $options->get_options( args => \@ARGV, spec => \@expected_options, callback => sub { my ($arg, $results) = @_; ... }, );
Convert command-line arguments to options, based on specified rules.
Returns a hashref of options or undef if an error occurred.
undef
args - Arguments from the caller (e.g. @ARGV).
args
@ARGV
spec - List of Getopt::Long compatible option strings.
spec
callback - Optional coderef to call for non-option arguments.
callback
config - Optional Getopt::Long configuration string.
config
$options->shell_completion($shell_type);
Print shell code to STDOUT for the given type of shell. When eval'd, the shell code enables completion for the git-codeowners command.
STDOUT
$options->completions($current_arg_index, @args);
Print completions to STDOUT for the given argument list and cursor position, and exit.
May also exit with status 9 and a compgen action printed to STDOUT to indicate that the shell should generate its own completions.
Doesn't return.
Please report any bugs or feature requests on the bugtracker website https://github.com/chazmcgarvey/git-codeowners/issues
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.
Charles McGarvey <chazmcgarvey@brokenzipper.com>
This software is copyright (c) 2019 by Charles McGarvey.
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 App::Codeowners, copy and paste the appropriate command in to your terminal.
cpanm
cpanm App::Codeowners
CPAN shell
perl -MCPAN -e shell install App::Codeowners
For more information on module installation, please visit the detailed CPAN module installation guide.