[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

tempfile <-> IO::Handle::new_tmpfile?


   can I use IO::Handle::new_tmpfile in an Perl script that's run on
 postinst? The package has to Predepend on perl, right? I'll use this
 tempfile to modify a conffile (it *has* to be modified, it's not an
 option)... what's the proper way of moving the file back into place?
 I think:

   system "cat $tempfile > $conffile";

 is ok (that's in order to preserve permissions and because rename
 doesn't work across file systems). (Sidenote: perhaps this whole
 question should go into that document Manoj is preparing)

 BTW, Why isn't File.pm included on perl-base? Several other IO things
 are there...


To UNSUBSCRIBE, email to debian-mentors-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

Reply to: