File::...r::Temp(3pm)

πŸ“¦
version 0.0.8 Β· 2 versions
  • 0.0.8 Β· debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking (latest)
  • 0.0.8 Β· ubuntu jammy
, in debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking

πŸ’– File::Fu::Dir::Temp β€” the manual page, but make it cute πŸ’–

okay bestie, welcome to the File::Fu::Dir::Temp page from the User Contributed Perl Documentation. it's all about temporary directories β€” the little throwaway folders that clean themselves up so you don't have to. iconic behaviour honestly. πŸŽ€


✨ NAME ✨

File::Fu::Dir::Temp β€” temporary directories. yes that's the whole name section, she's brief and she's booked. πŸ’…


🌸 SYNOPSIS 🌸

first things first, pull in the parent and grab yourself a temp dir:

use File::Fu;
my $dir = File::Fu->temp_dir;

then the fun little methods, one by one:

πŸ¦‹ new

make a new one, with a starting dir and a name:

my $tmp = File::Fu::Dir::Temp->new($dir, 'foo');

πŸ¦‹ chdir

hop into it and get the dir back:

my $dir = $dir->chdir;

πŸ¦‹ rename

literally the same as the base rename(), BUT β€” and this is the glow-up β€” it promotes the temp dir to a regular Dir object. that means no more cleanup actions, ever. it's a real dir now, it's got main character energy. πŸ‘‘

$temp = $temp->rename($dest);

πŸ¦‹ nocleanup

turn off the autocleanup. you're saying "no thank you, I'll handle this myself."

$dir->nocleanup;

πŸ¦‹ DESTROY

gets called automatically the moment the object goes out of scope. it's not a ghost, it's just tidy. 🫢

$dir->DESTROY;

πŸ’œ AUTHOR πŸ’œ

Eric Wilhelm @ <ewilhelm at cpan dot org>

http://scratchcomputing.com/


😭 BUGS 😭

if you found this module on CPAN, pls report any bugs or feature requests through the web interface at <http://rt.cpan.org>. he gets notified, and then you automatically get notified about progress on your bug as changes get made. closed loop, we love to see it. ✨

if you pulled this development version from his /svn/, hit him up directly instead.


Copyright (C) 2008 Eric L. Wilhelm, All Rights Reserved.


πŸ’€ NO WARRANTY πŸ’€

Absolutely, positively NO WARRANTY, neither express or implied, is offered with this software. You use this software at your own risk. In case of loss, no person or entity owes you anything whatsoever. You have been warned.

bestie this is not a drill, there is genuinely zero warranty here, not even the implied kind, and if something goes sideways nobody owes you anything. take it seriously fr fr. πŸ’€

🌈 LICENSE 🌈

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.


and that's the whole page, bestie, you ate it. πŸ“ this was File::Fu::Dir::Temp from the Perl v5.36.0 docs, dated 2022-12-07, living under the File::...r::Temp(3pm) name at the top and bottom of the original. go make some temp dirs, stay slay, don't forget the cleanup. πŸ’…βœ¨

πŸ“¦ where this page comes from