MacOSX::File::Exchange - Perl access to the exchangedata system call
use MacOSX::File::Exchange; exchangedata("newfile", "oldfile");
use MacOSX::File::Exchange qw(:all); exchangedata("newfile", "oldfile", FSOPT_NOFOLLOW);
The Darwin/Mac OS X system call
exchangedata atomically exchanges the contents and modification dates of two regular files, leaving all other metadata unchanged (this includes the inode numbers).
Expected arguments are two path strings and a flags integer. An omitted flags argument is interpreted as 0.
Do not follow leaf symlinks in paths.
exchangedata(2) in your Darwin manual.
Bo Lindbergh, <email@example.com>
Copyright (C) 2013 by Bo Lindbergh
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.9 or, at your option, any later version of Perl 5 you may have available.