App-Slaughter
view release on metacpan or search on metacpan
lib/Slaughter/API/generic.pm view on Meta::CPAN
{
#
# Find the current UID/GID of the file, so we
# can change just the owner.
#
my ( $dev, $ino, $mode, $nlink, $orig_uid,
$orig_gid, $rdev, $size, $atime, $mtime,
$ctime, $blksize, $blocks
)
= stat($file);
$::verbose && print "\tSetting owner to $owner/$uid\n";
chown( $uid, $orig_gid, $file );
$changed += 1;
}
if ( $params{ 'Group' } )
{
#
# Find the current UID/GID of the file, so we
# can change just the group.
#
my ( $dev, $ino, $mode, $nlink, $orig_uid,
$orig_gid, $rdev, $size, $atime, $mtime,
$ctime, $blksize, $blocks
)
= stat($file);
$::verbose && print "\tSetting group to $group/$gid\n";
chown( $orig_uid, $gid, $file );
$changed += 1;
}
if ( $params{ 'Mode' } )
{
$::verbose && print "\tSetting mode to $mode\n";
my $mode = $params{ 'Mode' };
( run in 0.818 second using v1.01-cache-2.11-cpan-49f99fa48dc )