Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re: path in tar file...please help

by gamache (Friar)
on Oct 10, 2007 at 21:04 UTC ( [id://644091]=note: print w/replies, xml ) Need Help??


in reply to path in tar file...please help

The answer is in tar, not perl. One of the following lines will do what you want: using tar's -C (change directory) option:
$cmd = "tar vvcCf $UploadDir $UploadDir/results.tar en_ran.out en-ave. +out ...";
or using shell tricks:
$cmd = "cd $UploadDir && tar vvcf results.tar en_ran.out en-ave.out .. +.";

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://644091]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others musing on the Monastery: (7)
As of 2024-04-18 02:49 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found