Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Dist-Zilla CPAN distribution.

Report information
The Basics
Id: 64383
Status: stalled
Priority: 0/
Queue: Dist-Zilla

Owner: Nobody in particular
Requestors: KENTNL [...]

Bug Information
Severity: Important
Broken in: 4.200000
Fixed in: (no value)

Subject: PruneCruft has ambiguous 'except' handling leading to files being included from build-dir
If PruneCruft has an except rule like so

except= \.foo$

once Dist-Name-* is populated the first time, the structure looks like so: 


and  subsequent calls to build result in

This makes sense when you understand how it works internally, but its unintuitive.

  return 0 if $self->_dont_exclude_file($file);
  return 1 if index($file->name, $self->zilla->name . '-') == 0;

So, the rule to include it overwrites the rule to exclude it. 

Thats fine, but I'm not thinking about stuff in Dist-Name-Version, the first time I call build it doesn't even exist.

  return 1 if index($file->name, $self->zilla->name . '-') == 0;
  return 0 if $self->_dont_exclude_file($file);

is more what I expected. 

This quirk should probably be documented, or perhaps changed. 

I'm contemplating a PruneCruft::BuildDir which is uninterruptable by prunecruft exclusion rules. 

Download (untitled) / with headers
text/plain 133b
A patch to make exceptions not apply to the build dir portion of PruneCruft would be welcome, as long as it includes tests. -- rjbs

This service is sponsored and maintained by Best Practical Solutions and runs on infrastructure.

Please report any issues with to