MacOSX::File - A collection of modules to manipulate files on MacOS X
As of Mac OS X v10.4 (Tiger), most of these operations with resource fork are supported by the ordinary (cp|mv|rsync). If you are looking for psync, you may as well consider using rsync -E instead.
MacOSX::File is a collection of modules that allows you to do what binaries in /Developer/Tools allows you to do directly via perl. You can implement your own CpMac, MvMac, GetFileInfo and SetFile without calling these binaries.
Others are defined in other submodules. see SUBMODULES below.
by default: unlink(), strerr()
on request: $OSErr, $CopyErr
Just like CORE::unlink, deletes a list of files. Returns the number of files successfully deleted. In addition to that, MacOSX::File::unlink also attempts to delete '._' files, files used in UFS volume to store Finder attributes and Resouce fork.
$cnt = unlink 'a', 'b', 'c'; # deletes 'a', 'b', 'c' # and '._a', '._b', '._c' # and returns 3 if all of them are # unlinked
Return string representation of File Manager errors if any. See MacOSX::File::Constants for details.
MacOSX::File::Catalog - Gets/Sets FSCatalogInfo Attributes MacOSX::File::Copy - copy/move with HFS(+) attributes MacOSX::File::Info - Gets/Sets File Attributes (Subset of ::Catalog) MacOSX::File::Spec - Gets FSSpec Structure
pcpmac - CpMac reimplemented pmvmac - MvMac reimplemented pgetfinfo - GetFileInfo reimplemented psetfinfo - SetFile reimplemented psync - update copy utility, very reason I wrote this module
To install this module, first make sure Developer kit is installed. Then type the following:
perl Makefile.PL make make test make install
This module requires MacOS X. Develper kit is needed to "make install".
Copyright 2002-2003 Dan Kogai <dankogai@dan.co.jp>
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install MacOSX::File, copy and paste the appropriate command in to your terminal.
cpanm
cpanm MacOSX::File
CPAN shell
perl -MCPAN -e shell install MacOSX::File
For more information on module installation, please visit the detailed CPAN module installation guide.