I have a subdirectory in my Perl Module root directory that I don't want to release.
I tried using "prune_directory" or "exclude_file" properties of https://metacpan.org/pod/Dist::Zilla::Plugin::GatherDir
I tried to specify the [GatherDir] section, but this conflicted as duplicate with @Basic, so in my dist.ini now I have (full file: https://github.com/telatin/FASTQ-Parser/blob/master/dist.ini):
[@Basic]
prune_directory = experimental
When building with dzil build --verbose i have all the lines like:
[@Basic/GatherDir] adding file experimental/scripts/my.pl
so the directory I wanted to prune is indeed added.
What should I do?
The
@Basicplugin bundle cannot pass through options to the plugins it uses. So you must first remove theGatherDirplugin from it using the @Filter bundle, and then useGatherDiryourself with the extra options.Another option is to use the @ConfigSlicer bundle to modify the plugin
@Basicuses directly.(The
[]in this case is because setting multi-value options through Config::Slicer requires the indication that it's multi-value. See the docs for details.)Consider the @Starter bundle, a modernized version of
@Basicthat allows-removeand config slicing options by default, as well as many other improvements and options based on modern Dist::Zilla practices.