From Code to Community: Sponsoring The Perl and Raku Conference 2025 Learn more

use Dancer ':syntax';
# demonstrator that we can put something in vars
# and wrap/augment a python worker with some other stuff
register_worker({ phase => 'early' }, sub {
my ($job, $workerconf) = @_;
my $file = $job->extra and return;
vars->{'file_to_lint'} ||=
Path::Class::Dir->new( $ENV{DANCER_ENVDIR} )
->file( $ENV{DANCER_ENVIRONMENT} .'.yml' )->stringify;
});
true;