PerlIO::creat - Creates a file if it doesn't exist
open my $io, '+< :creat', 'foo.txt';
PerlIO::creat appends O_CREAT to the open flags.
PerlIO::creat
O_CREAT
When you'd like to create a file but not to truncate it, you can use the :creat layer with an open mode '<' or '+<'.
:creat
This is a pseudo layer that doesn't be pushed on the layer stack.
PerlIO::Util.
PerlIO::excl.
"sysopen" in perlfunc.
Goro Fuji (藤 吾郎) <gfuji (at) cpan.org>
Copyright (c) 2008, Goro Fuji <gfuji (at) cpan.org>. Some rights reserved.
This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install PerlIO::Util, copy and paste the appropriate command in to your terminal.
cpanm
cpanm PerlIO::Util
CPAN shell
perl -MCPAN -e shell install PerlIO::Util
For more information on module installation, please visit the detailed CPAN module installation guide.