MooX::Options::Docs::ImportParameters - Import Parameters of MooX::Options
version 4.000
The list of parameters support by MooX::Options.
Pass extra arguments for Getopt::Long::Descriptive. it is usefull if you want to configure Getopt::Long.
use MooX::Options flavour => [qw( pass_through )];
Any flavour is pass to Getopt::Long as a configuration, check the doc to see what is possible.
By default, argv is protected. if you want to do something else on it, use this option and it will change the real argv.
use MooX::Options protect_argv => 0;
You can skip some option to remove them to the terminal. In that case, the 'option' keyword will just works like an 'has'.
use MooX::Options skip_options => [qw/multi/];
If you have multiple tools that use the same Role with options, you can skip one and force his value. In my example, it could be a multithread option that you want to disable in some cases.
By default, arguments to new_with_options have a higher priority than the commandline options.
This parameter give to the commandline an higher priority.
use MooX::Options prefer_commandline => 1;
This parameter will load MooX::ConfigFromFile in your module. The config option will be used between the commandline and the parameters.
MyTools :
use MooX::Options with_config_from_file => 1;
In /etc/MyTools.json
{"test" : 1}
MooX::Options
Please report any bugs or feature requests on the bugtracker website https://github.com/celogeek/MooX-Options/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.
celogeek <me@celogeek.com>
This software is copyright (c) 2013 by celogeek <me@celogeek.com>.
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 MooX::Options, copy and paste the appropriate command in to your terminal.
cpanm
cpanm MooX::Options
CPAN shell
perl -MCPAN -e shell install MooX::Options
For more information on module installation, please visit the detailed CPAN module installation guide.