in reply to Re: Better way to use File::Find and Archive::Tar
in thread Better way to use File::Find and Archive::Tar
Here's what I changed in my code:./web_dir ./cgi-bin ./www ./etc
When I un-tar it, all of the the files and directories underneath the web_dir are created separately instead of getting created under the web_dir.... chdir("$web_base/$web_to_del"); find(\&archive, "."); ...
Now if I just change into the directory directly above it, the tar file is created with just the web_dir and no other files or directories below it. Code:
I've tried a couple of other variations than this as well, but I get comparable (wrong) results.... chdir("$web_base"); find(\&archive, "$web_to_del"); ...
|
|---|