view release on metacpan or search on metacpan
run-and-save view on Meta::CPAN
case $line in
\#!*)
printf '%s\n\n' "$line" >&3;;
\#COMMIT)
printf '#!/bin/sh\n\n:\n' >&3
chmod u+x "$saveas"
exec 3>&-
test "${saveas#/}" = "$saveas" && exec "./$saveas"
exec "$saveas";;
\#ROLLBACK)
exit 1;;
run-and-save view on Meta::CPAN
while read -r line; do
case $line in
\#COMMIT)
mv -b -f "$tmp" "$saveas"
chmod u+x "$saveas"
exec 3>&-
test "${saveas#/}" = "$saveas" && exec "./$saveas"
exec "$saveas";;
\#ROLLBACK)
exit 1;;
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Config/Model/models/Itself/Class.pl view on Meta::CPAN
type => 'leaf',
value_type => 'uniline',
level => 'normal',
summary => 'configuration file mode',
description => 'specify the configuration file mode. C<file_mode> parameter can be used to set the '
. 'mode of the written file. C<file_mode> value can be in any form supported by L<Path::Tiny/chmod>.'
},
default_layer => {
type => 'node',
config_class_name => 'Itself::ConfigReadWrite::DefaultLayer',
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Config/Model/Backend/PlainFile.pm view on Meta::CPAN
}
if (@v) {
$logger->trace("PlainFile write opening $file to write $elt");
$file->spew_utf8(@v);
$file->chmod($args{file_mode}) if $args{file_mode};
}
elsif ($file->exists) {
$logger->trace("PlainFile delete $file");
$file->remove;
}
lib/Config/Model/Backend/PlainFile.pm view on Meta::CPAN
string_b=else>, this backend writes "C<something>" in file
C<example.string_a> and C<else> in file C<example.string_b>.
C<file_mode> parameter can be used to set the mode of the written
file. C<file_mode> value can be in any form supported by
L<Path::Tiny/chmod>.
=head1 Methods
=head2 read_leaf
view all matches for this distribution
view release on metacpan or search on metacpan
t/01_basic.t view on Meta::CPAN
my $tst = temppath();
my $fh = $exe->open("w", 0700) or die "open failed.";
print $fh file("t/editor/exe$suffix")->slurp;
undef $fh;
chmod 0700, $exe;
$ENV{EDITOR} = $exe;
$ENV{TEST_FILE} = $tst;
#system $exe, "Changes";
#p $tst->slurp;
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Config/Proxy/Base.pm view on Meta::CPAN
$self->backup;
rename($tempfile, $self->filename)
or croak "can't rename $tempfile to ".$self->tempfile.": $!";
# This will succeed: we've created the file, so we're owning it.
chmod $sb->mode & 0777, $self->filename;
# This will fail unless we are root, let it be so.
chown $sb->uid, $sb->gid, $self->filename;
$self->tree->clear_dirty;
return 1;
view all matches for this distribution
view release on metacpan or search on metacpan
t/02-perm.t view on Meta::CPAN
use Test::More tests => 4;
use File::Spec;
BEGIN { use_ok('Config::Scoped') }
my $unsafe_cfg = File::Spec->catfile( 't', 'files', 'fvalid.cfg' );
chmod 0664, $unsafe_cfg;
my ($p, $cfg);
isa_ok($p = Config::Scoped->new(file => $unsafe_cfg), 'Config::Scoped');
eval { $cfg = $p->parse; };
isa_ok($@, 'Config::Scoped::Error::Validate::Permissions');
view all matches for this distribution
view release on metacpan or search on metacpan
# --- MakeMaker tool_xsubpp section:
# --- MakeMaker tools_other section:
CHMOD = $(ABSPERLRUN) -MExtUtils::Command -e chmod --
CP = $(ABSPERLRUN) -MExtUtils::Command -e cp --
MV = $(ABSPERLRUN) -MExtUtils::Command -e mv --
NOOP = rem
NOECHO = @
RM_F = $(ABSPERLRUN) -MExtUtils::Command -e rm_f --
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Config/Writer.pm view on Meta::CPAN
Configuration file group name. If not provided, process EGID is used.
=item B<permissions> = OCTAL
Configuration file permissions in numeric format. Read B<chmod(1)> manual for
details.
Default is 0600.
=back
view all matches for this distribution
view release on metacpan or search on metacpan
CONTRIBUTING.md view on Meta::CPAN
Dependencies for this module are recorded in the `META.json` file.
Installation is most easily done with `cpanminus`[1], which can be
made available locally via:
$ curl -L https://cpanmin.us/ -o cpanm
$ chmod +x cpanm
To install the dependencies into a local directory (to avoid polluting
your Perl distribution),
$ export PERL5LIB=${PERL5LIB}:$PWD/local
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Conjury/Core.pm view on Meta::CPAN
list, they need not be listed here. They will be fetched and automatically
appended to the factors list.
Use the optional 'Journal' argument to specify a journal object for the spell.
Use the optional 'Permission' argument to specify that the C<chmod> builtin
should be used to set the access permissions associated with the files after
they have been copied to the destination. The syntax requirements for
C<chmod> apply.
Use the optional 'Owner' argument to specify that the C<chown> builtin should
be used to set the user and group ownership after the files have been copied to
the destination. The syntax requirements for C<chown> apply.
lib/Conjury/Core.pm view on Meta::CPAN
}
}
if (defined($permission)) {
my $valstr = sprintf "%o", $permission;
print "chmod $valstr $product_str\n";
if (!$preview) {
chmod($permission, @product) == @product
|| do {
my $result = $!;
unlink @product;
return $result;
};
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Connector/Builtin/File/Path.pm view on Meta::CPAN
print FILE $content;
close FILE;
if (my $filemode = $self->mode()) {
if ($filemode =~ m{\A[0-7]{4}\z}) {
chmod (oct($filemode), $filename) || die "Unable to change mode to $filemode";
} else {
die "Given mode string '$filemode' is not valid";
}
}
view all matches for this distribution
view release on metacpan or search on metacpan
Makefile.PL view on Meta::CPAN
PREREQ_PM => {
#'ABC' => '1.6',
#'Foo::Bar::Module' => '5.0401',
},
dist => {
PREOP => 'pod2text lib/Const/Dual.pm | tee README >$(DISTVNAME)/README; chmod -R u=rwX,go=rX . ;',
COMPRESS => 'gzip -9v',
SUFFIX => '.gz',
},
);
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Contenticious/Generator.pm view on Meta::CPAN
make_path $target_dir unless -d $target_dir;
# dump file
copy $source => $target;
# chmod executable if neccessary
chmod oct(755) => $target if $self->is_executable($filename);
}
1;
__END__
view all matches for this distribution
view release on metacpan or search on metacpan
# --- MakeMaker tools_other section:
SHELL = /bin/sh
CHMOD = chmod
CP = cp
LD = gcc
MV = mv
NOOP = $(SHELL) -c true
RM_F = rm -f
POD2MAN_EXE = /usr/local/appl/perl/solaris2.5.1/bin/pod2man
POD2MAN = $(PERL) -we '%m=@ARGV;for (keys %m){' \
-e 'next if -e $$m{$$_} && -M $$m{$$_} < -M $$_ && -M $$m{$$_} < -M "Makefile";' \
-e 'print "Manifying $$m{$$_}\n";' \
-e 'system(qq[$$^X ].q["-I$(PERL_ARCHLIB)" "-I$(PERL_LIB)" $(POD2MAN_EXE) ].qq[$$_>$$m{$$_}])==0 or warn "Couldn\047t install $$m{$$_}\n";' \
-e 'chmod(oct($(PERM_RW))), $$m{$$_} or warn "chmod $(PERM_RW) $$m{$$_}: $$!\n";}'
manifypods : pure_all Continuus.pm
@$(POD2MAN) \
Continuus.pm \
$(INST_MAN3DIR)/Continuus.$(MAN3EXT)
view all matches for this distribution
view release on metacpan or search on metacpan
unless (-f $log_config_file) {
open LC, ">$log_config_file"
or croak "Cannot create $log_config_file: $!";
print LC ${ ControlFreak::Logger->default_config };
close LC;
chmod 0622, $log_config_file;
}
}
daemonize() if $options{daemon};
view all matches for this distribution
view release on metacpan or search on metacpan
Makefile.PL view on Meta::CPAN
use Canary::Stability Convert::BER::XS => 1, 5.008009;
WriteMakefile(
dist => {
PREOP => 'pod2text XS.pm | tee README >$(DISTVNAME)/README; chmod -R u=rwX,go=rX . ;',
COMPRESS => 'gzip -9v',
SUFFIX => '.gz',
},
NAME => "Convert::BER::XS",
VERSION_FROM => "XS.pm",
view all matches for this distribution
view release on metacpan or search on metacpan
bin/convert.PL view on Meta::CPAN
join ' ', map { sprintf "%02X", $_ } unpack "C*", $_[0];
}
!NO!SUBS!
close OUT or die "Can't close $file: $!";
chmod 0755, $file or die "Can't reset permissions for $file: $!\n";
view all matches for this distribution
view release on metacpan or search on metacpan
Makefile.PL view on Meta::CPAN
use Canary::Stability Convert::Scalar => 1, 5.008;
WriteMakefile(
dist => {
PREOP => 'pod2text Scalar.pm | tee README >$(DISTVNAME)/README; chmod -R u=rwX,go=rX . ;',
COMPRESS => 'gzip -9v',
SUFFIX => '.gz',
},
NAME => "Convert::Scalar",
VERSION_FROM => "Scalar.pm",
view all matches for this distribution
view release on metacpan or search on metacpan
Makefile.PL view on Meta::CPAN
),
);
sub MY::postamble {
q{README: lib/Convert/UU.pm Makefile
chmod +w $@
pod2text lib/Convert/UU.pm > $@
}
}
view all matches for this distribution
view release on metacpan or search on metacpan
Makefile.PL view on Meta::CPAN
END
}
WriteMakefile(
'dist' => {
PREOP => 'pod2text UUlib.pm | tee README >$(DISTVNAME)/README; chmod -R u=rwX,go=rX . ; chmod -R u=rwX,go=rX . ;',
COMPRESS => 'gzip -9v',
SUFFIX => '.gz',
},
'NAME' => 'Convert::UUlib',
'VERSION_FROM' => 'UUlib.pm',
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Convos/Manual/Running.pod view on Meta::CPAN
It's possible to generate init scripts for L<Convos> now. To do that, you can
run these commands:
for i in frontend backend; do
convos $i get_init_file > /etc/init.d/convos-$i
chmod +x /etc/init.d/convos-$i
update-rc.d convos-$i defaults
done
The backend and frontend can be supplied with environment variables from
C</etc/default/convos>. Example:
view all matches for this distribution
view release on metacpan or search on metacpan
Makefile.PL view on Meta::CPAN
use 5.008002;
my $mm = MM->new({
dist => {
PREOP => 'pod2text MP.pm | tee README >$(DISTVNAME)/README; chmod -R u=rwX,go=rX . ;',
COMPRESS => 'gzip -9v',
SUFFIX => '.gz',
},
NAME => "Coro::MP",
VERSION_FROM => "MP.pm",
view all matches for this distribution
view release on metacpan or search on metacpan
Makefile.PL view on Meta::CPAN
my $define = sprintf "-DRECURSION_CHECK=%d", $extra;
WriteMakefile(Coro::MakeMaker::coro_args(
dist => {
PREOP => 'pod2text Multicore.pm | tee README >$(DISTVNAME)/README; chmod -R u=rwX,go=rX . ;',
COMPRESS => 'gzip -9v',
SUFFIX => '.gz',
},
NAME => "Coro::Multicore",
VERSION_FROM => "Multicore.pm",
view all matches for this distribution
view release on metacpan or search on metacpan
Makefile.PL view on Meta::CPAN
$val
}
my %wm = (
dist => {
PREOP => 'pod2text Mysql.pm | tee README >$(DISTVNAME)/README; chmod -R u=rwX,go=rX . ;',
COMPRESS => 'gzip -9v',
SUFFIX => '.gz',
},
PREREQ_PM => {
Scalar::Util => 0.00,
view all matches for this distribution
view release on metacpan or search on metacpan
Makefile.PL view on Meta::CPAN
print "\n*** EV not found, not building EV support.\n\n";
}
WriteMakefile(
dist => {
PREOP => 'pod2text Coro.pm | tee README >$(DISTVNAME)/README; chmod -R u=rwX,go=rX . ;',
COMPRESS => 'gzip -9v',
SUFFIX => '.gz',
},
NAME => "Coro",
VERSION_FROM => "Coro.pm",
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Courier/Filter.pm view on Meta::CPAN
rename($socket_prename, $socket_name)
or unlink($socket_prename),
throw Courier::Error("Unable to rename socket $socket_prename to $socket_name");
chmod(0660, $socket_name)
or throw Courier::Error("Unable to chmod socket $socket_name");
IO::Handle->new_from_fd(3, '>')->close();
my $filter = {
name => $name,
view all matches for this distribution
view release on metacpan or search on metacpan
Makefile.PL view on Meta::CPAN
}
}
WriteMakefile(
dist => {
PREOP => 'pod2text XS.pm | tee README >$(DISTVNAME)/README; chmod -R u=rwX,go=rX . ;',
COMPRESS => 'gzip -9v',
SUFFIX => '.gz',
},
EXE_FILES => [ "bin/cpanel_json_xs" ],
VERSION_FROM => "XS.pm",
view all matches for this distribution
view release on metacpan or search on metacpan
Makefile.PL view on Meta::CPAN
$PREOP =<<'EOP';
$(FULLPERL) -I$(PERL_ARCHLIB) -I$(PERL_LIB) \
-e "$$dir = $$ARGV[0];use File::Find;" \
-e "find(\&process, $$dir); sub process { return if -d || /\.dll$$/i;" \
-e "open(I,$$_) || die \"to_unix: can't read file `$$_'\n\";" \
-e "@file = <I>; close I;chmod 0666, $$_;" \
-e "open(O,\">$$_\") || die \"to_unix: can't write file `$$_'\n\";" \
-e "binmode O;print O map { s/\r\n/\n/;$$_ } @file; close O; }" $*
EOP
use ExtUtils::MakeMaker;
view all matches for this distribution
view release on metacpan or search on metacpan
Makefile.PL view on Meta::CPAN
use Canary::Stability Crypt::Ed25519 => 1;
WriteMakefile(
dist => {
PREOP => 'pod2text Ed25519.pm | tee README >$(DISTVNAME)/README; chmod -R u=rwX,go=rX . ;',
COMPRESS => 'gzip -9v',
SUFFIX => '.gz',
},
NAME => "Crypt::Ed25519",
VERSION_FROM => "Ed25519.pm",
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Crypt/ppport.h view on Meta::CPAN
check_type_and_open|5.009003||Viu
check_uni|5.003007||Viu
check_utf8|5.008000||Viu
check_utf8_print|5.013009||Viu
child_offset_bits|5.009003||Viu
chmod|5.005000||Viu
chsize|5.005000||Viu
ckDEAD|5.006000||Viu
ck_entersub_args_core|||iu
ck_entersub_args_list|5.013006|5.013006|
ck_entersub_args_proto|5.013006|5.013006|
lib/Crypt/ppport.h view on Meta::CPAN
KEY_break|5.027008||Viu
KEY_caller|5.003007||Viu
KEY_catch|5.033007||Viu
KEY_chdir|5.003007||Viu
KEY_CHECK|5.006000||Viu
KEY_chmod|5.003007||Viu
KEY_chomp|5.003007||Viu
KEY_chop|5.003007||Viu
KEY_chown|5.003007||Viu
KEY_chr|5.003007||Viu
KEY_chroot|5.003007||Viu
lib/Crypt/ppport.h view on Meta::CPAN
Perl_langinfo|5.027004|5.027004|n
PERL_LANGINFO_H|5.027004||Viu
PERL_LAST_5_18_0_INTERP_MEMBER|5.017009||Viu
Perl_ldexp|5.021003|5.021003|n
PerlLIO_access|5.005000||Viu
PerlLIO_chmod|5.005000||Viu
PerlLIO_chown|5.005000||Viu
PerlLIO_chsize|5.005000||Viu
PerlLIO_close|5.005000||Viu
PerlLIO_dup2|5.005000||Viu
PerlLIO_dup2_cloexec|5.027008||Viu
lib/Crypt/ppport.h view on Meta::CPAN
Perl_pp_aelemfast_lex|5.015000||Viu
Perl_pp_andassign|5.013009||Viu
Perl_pp_avalues|5.013009||Viu
Perl_pp_bind|5.013009||Viu
Perl_pp_bit_xor|5.013009||Viu
Perl_pp_chmod|5.013009||Viu
Perl_pp_chomp|5.013009||Viu
Perl_pp_connect|5.013009||Viu
Perl_pp_cos|5.013009||Viu
Perl_pp_custom|5.013009||Viu
Perl_pp_dbmclose|5.013009||Viu
view all matches for this distribution