LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   overwrite directory copy (https://www.linuxquestions.org/questions/linux-newbie-8/overwrite-directory-copy-21858/)

medamnit 05-26-2002 11:59 AM

overwrite directory copy
 
i'm backing up a few files & dirs into a directory.

cp -R /dir/ /tmpdir/

how do i overwrite the previous backup. just say if i backup on sat'day, run the command on sunday, the sat'day files are still there and are not updated.

am i doin this right? any other suggestions would be great.

thank you
medamnit

MartBrooks 05-26-2002 12:09 PM

Don't confuse copying files with backing them up. :)

Files of the same name will be overwritten by the newer copy. Orphaned files will be left untouched. If you want to only copy your current fileset, delete the old one first.

Regards


All times are GMT -5. The time now is 10:50 AM.