MooseX...::Basic(3pm)
β¨ NAME β¨
bestie. say hi to MooseX::Getopt::Basic π β it's a role that implements the Getopt::Long functionality for you, so your class can just... read the command line like it's nothing. periodt.
πΈ VERSION πΈ
version 0.78 π
π¦ SYNOPSIS π¦
okay so first, in your class:
## In your class
package My::App;
use Moose;
with 'MooseX::Getopt::Basic';
has 'out' => (is => 'rw', isa => 'Str', required => 1);
has 'in' => (is => 'rw', isa => 'Str', required => 1);
# ... rest of the class here
then in your script:
## in your script
#!/usr/bin/perl
use My::App;
my $app = My::App->new_with_options();
# ... rest of the script here
and then on the command line, the moment of truth β¨:
## on the command line
% perl my_app_script.pl --in file.input --out file.dump
like. that's it. that's the whole vibe. π
π DESCRIPTION π
so MooseX::Getopt::Basic is basically MooseX::Getopt's twin β you can use it instead β with one lil' difference: it does not make use of Getopt::Long::Descriptive (or "GLD" for short). no GLD, no problem, bestie π«Ά.
π METHODS π
β new_with_options
See "new_with_options" in MooseX::Getopt. iykyk π
β process_argv
See "process_argv" in MooseX::Getopt. same energy, go look π
π SUPPORT π
got bugs? they may be submitted through the RT bug tracker at <https://rt.cpan.org/Public/Dist/Display.html?Name=MooseX-Getopt> π (or, if you're feeling email-y, bug-MooseX-Getopt@rt.cpan.org <mailto:bug-MooseX-Getopt@rt.cpan.org>).
there's also a mailing list for users of this distribution, living at <http://lists.perl.org/list/moose.html> π
and there's an irc channel for users of this distribution too, at "#moose" on "irc.perl.org" <irc://irc.perl.org/#moose> β come hang, fr fr πΈ
π AUTHOR π
Stevan Little <stevan@iinteractive.com> β icon, legend, the moment π
π COPYRIGHT AND LICENSE π
This software is copyright (c) 2007 by Infinity Interactive, Inc. π
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. slay. π
okay that's the whole page bestie!! this was pulled straight from the perl v5.40.0 docs, dated 2025-01-11, and the original header/footer said MooseX...::Basic(3pm) β mwah, go write something iconic πβ¨
π¦ where this page comes from
- debian trixie: libmoosex-getopt-perl 0.78-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu resolute: libmoosex-getopt-perl 0.78-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu stonking: libmoosex-getopt-perl 0.78-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms