Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
Using awk to make archives
Name: HunterColt22 Date: May 26, 2007 at 22:51:41 Pacific OS: Windows XP CPU/Ram: Centrino Duo Processor Product: HP Pavilion
Comment:
Hi everyone, I am currently in my first programming class and we are learning BASH, this has been the first time I have used Linux or a conjunction of it or Unix before this class. As of up untill now, I have been doing well and been able to figure it out on my own mostly. I am stuck on this on problem though. I need to make shell script that uses awk to archive my files and directories into seperate archives based on the month and year they were created on. It should also be able to take a command line arguement of a directory path to where it should be archived to. thanks a bunch for any help on this at all, thank you again.
Name: ghostdog Date: May 27, 2007 at 03:36:37 Pacific
Reply:
you can use a combination of find and tar. find is to find files according to your date and tar is to archive them. check your man pages. Also google for "find tar backup files".
0
Response Number 2
Name: HunterColt22 Date: May 27, 2007 at 19:03:03 Pacific
Reply:
Thanks for that bit of info, though wasnt exactly what I had a problem with. I knew I would have to find and tar them in the script, the only thing I can not figure it out is how to make files go into a certain archive if they were made on a certain month within a certain year, I know I would need to use the find 'date' for that but, I am not sure what to do after that. Thanks though, that gives me a bit more of an idea what to do.
Summary: hi: i am in a small trouble, i hope that somebody could help me. I have Linux Red Hat 7.0 on my Comp i am using lilo Boot floppy to load linux , the floppy is destroyed by chance .i can't make it wo...
Summary: Some how my main email account got added to a SPAM list and I am getting hammered with SPAM. I need to make it stop. Im using sendmail to send mail and fetchmail->procmail->mutt for reading. My quest...