Dist::Z...nderUser(3)

πŸ’– Dist::Z...nderUser(3) β€” aka Dist::Zilla::Role::FileFinderUser πŸ’–

okay bestie, welcome to the manual page for Dist::Zilla::Role::FileFinderUser (it's a Perl thing, it lives in the User Contributed Perl Documentation section, and yes the header got its name all squished, that's just the terminal being extra). VERSION? It's version 6.040. slay. ✨


🌸 NAME 🌸

Dist::Zilla::Role::FileFinderUser β€” literally "something that uses FileFinder plugins". that's the whole vibe. πŸ¦‹


✨ DESCRIPTION ✨

bestie. this role is the main character of file-hunting. it lets you search for files in the dist, which means finding specific files is lowkey effortless, and the code doing it gets factored out into common methods. obsessed. πŸ’…

here's an example of a finder, borrowed straight from AutoPrereqs:

with 'Dist::Zilla::Role::FileFinderUser' => {
    default_finders  => [ ':InstallModules', ':ExecFiles' ],
};

and then you actually use it in your code like this:

foreach my $file ( @{ $self->found_files }) {
  # $file is an object! Look at L<Dist::Zilla::Role::File>
}

note the comment: $file is an object, not just a string. look at Dist::Zilla::Role::File. iykyk. 🫢


🐧 PERL VERSION 🐧

ngl this part is a whole mood of its own. this module should work on any version of perl still receiving updates from the Perl 5 Porters. translated for the girlies: any perl released in the last two to three years. (so if the freshest release is v5.40, then this works on both v5.40 and v5.38. periodt.)

⚠️ and even though it might work on older perls, there is no guarantee the minimum required version won't get bumped. the version may be increased for any reason, and there's no promise that patches will be accepted to lower the minimum required perl. so don't come for her. 😭

πŸ‘‘ ATTRIBUTES πŸ‘‘

πŸ’œ finder_arg_names

defines the name of the attribute that's gonna hold this finder. be sure to specify different names if you have multiple finders! (yes this is shouting at you. listen.)

this is an ArrayRef.

Default: [ qw( finder ) ]

πŸ’œ default_finders

this attribute is an arrayref of plugin names for the default plugins that the consuming plugin will use as finders. iconic behaviour.

Example: [ qw( :InstallModules :ExecFiles ) ]

the default finders are:

  • :InstallModules β€” searches your lib/ directory for pm/pod files
  • :IncModules β€” searches your inc/ directory for pm files
  • :MainModule β€” finds the main_module of your dist
  • :TestFiles β€” searches your t/ directory and lists the files in it
  • :ExtraTestFiles β€” searches your xt/ directory and lists the files in it
  • :ExecFiles β€” searches your distribution for executable files. hint: use the Dist::Zilla::Plugin::ExecDir plugin to mark those files as executables πŸƒβ™€οΈ
  • :PerlExecFiles β€” a subset of :ExecFiles limited just to perl scripts (the ones ending with .pl, or with a recognizable perl shebang)
  • :ShareFiles β€” searches your ShareDir directory and lists the files in it. hint: use the Dist::Zilla::Plugin::ShareDir plugin to set up the sharedir 🌈
  • :AllFiles β€” returns all files in the distribution
  • :NoFiles β€” returns nothing. (she said what she said. πŸ’€)

πŸ’œ method

this will be the name of the subroutine installed in your package for this finder. and again β€” be sure to specify different names if you have multiple finders! two finders with the same method name is giving chaos, and not the cute kind. πŸ™ˆ

Default: found_files


πŸŽ€ AUTHOR πŸŽ€

Ricardo SIGNES 😏 <cpan@semiotic.systems> β€” yeah the emoji is literally in the source, we love a legend with range. πŸ’…


this software is copyright (c) 2026 by Ricardo SIGNES.

this is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. so go off, but respectfully. 🫢


and that's the whole page, bestie! πŸ’– this gorgeous little number is from perl v5.42.3, dated 2026-10-19, filed under Dist::Z...nderUser(3) β€” which, yes, is just Dist::Zilla::Role::FileFinderUser(3) with the name aggressively cropped by the man page formatter. she's compressed but she's thriving. bye bestie, go find some files! πŸ¦‹βœ¨πŸ’œ

πŸ“¦ where this page comes from