dagolden / Dist-Zilla-Plugin-OSPrereqs

List prereqs conditional on operating system
1 stars 5 forks source link

Cannot pass prereq_os via add_plugin #16

Open autarch opened 6 years ago

autarch commented 6 years ago

I have this code that I'm running:


    $self->add_plugins(
        [
            'OSPrereqs' => {
                prereq_os                          => 'MSWin32',
                'DateTime::TimeZone::Local::Win32' => $version,
            }
        ],
    );

Even with the 0.011 release I still get this warning: "[=DTTZBundle/OSPrereqs] inferred OS name as =DTTZBundle/OSPrereqs, which looks like it came from a bundle!"

The problem, AFAICT, is that the BUILDARGS is doing some odd munging of the passed-in args. I think it's trying to filter out module names from everything else. It does handle plugin_name explicitly, but not prereq_os.

autarch commented 6 years ago

It'd be great if this could be fixed.

Grinnz commented 5 years ago

It seems like the prereq_os option is broken in general - the plugin name is still used as the OS, and prereq_os gets added as a prereq.