On Wed, 2005-11-09 at 13:28 +0000, shail_linux wrote:
> As per the requirement backup is required for the past 4 days. I have
> created five folders- mon,tue,wed,thu,fri. Everyday i have to change
> the destination directory in the script. I want to automate this too.
> How can i go about it?

You could use something like:
whatday=`date +"%A"`
then check what the day is with an if or case statements.

Or you could change your directory names to match the output of the date
command (like change wed to Wednesday). Then
use /path/to/backup/folder/$whatday for you backup path.

HTH, 
--
Doug

Registered Linux User #285548 (http://counter.li.org)
----------------------------------------
Random Thought:
That is the true season of love, when we believe that we alone can love,
that no one could have loved so before us, and that no one will love
in the same way as us.
                -- Johann Wolfgang von Goethe



------------------------ Yahoo! Groups Sponsor --------------------~--> 
Get Bzzzy! (real tools to help you find a job). Welcome to the Sweet Life.
http://us.click.yahoo.com/A77XvD/vlQLAA/TtwFAA/0XFolB/TM
--------------------------------------------------------------------~-> 

To unsubscribe from this list, please email [EMAIL PROTECTED] & you will be 
removed. 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/LINUX_Newbies/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to