/usr/share/perl5/Carton/Snapshot/Emitter.pm is in carton 1.0.12-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 | package Carton::Snapshot::Emitter;
use Moo;
use warnings NONFATAL => 'all';
sub emit {
my($self, $snapshot) = @_;
my $data = '';
$data .= "# carton snapshot format: version @{[$snapshot->version]}\n";
$data .= "DISTRIBUTIONS\n";
for my $dist (sort { $a->name cmp $b->name } $snapshot->distributions) {
$data .= " @{[$dist->name]}\n";
$data .= " pathname: @{[$dist->pathname]}\n";
$data .= " provides:\n";
for my $package (sort keys %{$dist->provides}) {
$data .= " $package @{[$dist->provides->{$package}{version} || 'undef' ]}\n";
}
$data .= " requirements:\n";
for my $module (sort $dist->required_modules) {
$data .= " $module @{[ $dist->requirements_for_module($module) || '0' ]}\n";
}
}
$data;
}
1;
|