Your skill will accomplish what the force of many cannot |
|
PerlMonks |
Simple Perl Backup helpby laxman526 (Initiate) |
on Aug 03, 2012 at 19:17 UTC ( [id://985327]=perlquestion: print w/replies, xml ) | Need Help?? |
laxman526 has asked for the wisdom of the Perl Monks concerning the following question: Hey Everyone, I'm a Network Admin and just literally picked up programming within the last month. I'm loving Perl so far. But due to my lack of experience, I'm finding it difficult to write even the simplest if and else statements. Here is my very first program I wrote last night. Basically it takes an array of directories to back up, checks if the dirs exist then prompts a user for a "yes" or "no" response to back up. Then tarballs the directories and moves them to a different server. My issue is testing user input. I want the code to shorten up a bit. I'm hoping someone will have some insight into this. Also, I'm going to make this an rsync backup script at one point, but wanted to practice with tar and commands first. Also, I encourage general formatting, syntax, or anything else to help me along the way! Thanks everyone!
Back to
Seekers of Perl Wisdom
|
|