Getopt...toList(3pm)

πŸ“¦ version 2.000011, in ubuntu stonking

πŸ’– NAME πŸ’–

Getopt::Yath::Option::AutoList β€” bestie, it's options that come with a whole default list of values, no cap ✨


🌸 DESCRIPTION 🌸

Okay so picture this: it's a glow-up collab between the 'Auto' type and the 'List' type, and the result is genuinely iconic πŸ”₯

  • Hit it with the no-arg form, just plain --opt, and it takes the default value(s) and drops them straight into the list. Automatic. Effortless. We stan 🫢
  • Want something specific? Use the --opt=VAL form and it adds additional values on top. Mix and match, it's giving versatility πŸ’…

so basically: no args = the defaults show up, args = your args show up too. both. at once. iconic.


πŸŽ€ SYNOPSIS πŸŽ€

option do_things => (
    type => 'AutoList',
    autofill => sub { qw/foo bar baz/ },
);

✨ METHODS ✨

Every single method from Getopt::Yath::Option::List is inherited β€” the whole family tree came to the party, it's a reunion πŸ’œ The ones below are either overridden or just extra noteworthy:

  • requires_arg: false
  • allows_autofill: true
  • requires_autofill: true

And here's what that trio is actually saying, bestie:

  • --opt adds the autofill value(s) to the list 🌈
  • --opt=VAL adds one specific value 🎯
lowkey that's the whole vibe: bare flag = autofill defaults, flag with a value = your exact value. both roads lead to the list. πŸ‘‘

πŸ” SOURCE πŸ”

The source code repository for Getopt-Yath can be found at <http://github.com/Test-More/Getopt-Yath/> β€” go lurk, it's free πŸ’–


πŸ‘‘ MAINTAINERS πŸ‘‘

Chad Granum <exodist@cpan.org>


πŸ’ AUTHORS πŸ’

Chad Granum <exodist@cpan.org>


Copyright Chad Granum <exodist7@gmail.com>.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

See <http://dev.perl.org/licenses/>


manifesting your option parser works on the first try πŸŒ™πŸ“

kisses, this was perl v5.40.1, dated 2026-05-10 β€” Getopt...toList(3pm), and yes she served πŸ’…

πŸ“¦ where this page comes from