skip to main content

Package Information for perl-File-chmod 0.31-1

Name: perl-File-chmod Vendor: Jeff Pinyan <japhy@pobox.com>
Version: 0.31 Build Date: Fri Oct 13 16:48:20 2006
Release: 1 Build Host: kingsbarns.inf.ed.ac.uk
Group: Applications/CPAN Source: perl-File-chmod-0.31-1.src.rpm
Size: 32560 License: Artistic
Packager: Arix International <cpan2rpm-AT-arix.com> Arch: noarch
Summary: File-chmod - Implements symbolic and ls chmod modes
Description:  
File::chmod is a utility that allows you to bypass system calls or bit
processing of a file's permissions. It overloads the chmod() function
with its own that gets an octal mode, a symbolic mode (see below), or
an "ls" mode (see below). If you wish not to overload chmod(), you can
export symchmod() and lschmod(), which take, respectively, a symbolic
mode and an "ls" mode.

Symbolic modes are thoroughly described in your chmod(1) man page, but
here are a few examples.



chmod("+x","file1","file2"); # overloaded chmod(), that is...


chmod("o=,g-w","file1","file2");


chmod("=u","file1","file2");


"ls" modes are the type produced on the left-hand side of an C<ls -l> on a
directory. Examples are:

chmod("-rwxr-xr-x","file1","file2");



chmod("-rwsrws---","file1","file2");



The regular chmod() and lschmod() are absolute; that is, they are not
appending to or subtracting from the current file mode. They set it,
regardless of what it had been before. symchmod() is useful for allowing
the modifying of a file's permissions without having to run a system call
or determining the file's permissions, and then combining that with whatever
bits are appropriate. It also operates separately on each file.

An added feature to version 0.30 is the $UMASK variable, explained below; if
symchmod() is called and this variable is true, then the function uses the
(also new) $MASK variable (which defaults to umask()) as a mask against the
new mode. This is documented below more clearly.

Documentation Files

Click on a link to view the documentation file, pod files will be automatically converted into html.