On Tue, Sep 30, 2008 at 1:21 PM, <dudeja.rajat@g mail.comwrote:
You could probably whip one up very easily using the tarfile module
[http://docs.python.org/lib/module-tarfile.html] and shutil.move()
[http://docs.python.org/lib/module-shutil.html]. Just make a new
TarFile of the directory, save it, then replace any previous backup
file using shutil.move()
Good luck, and have fun!
Regards,
Chris
P.S. And if you're on *nix, you might consider just using a shell
script and the 'tar' command. Right tool for the right job and all
that.
--
Follow the path of the Iguana...
Hello,
>
>
I'm looking for a script that creates a backup of a directory but keeps only
one backup.
I've tried using all the os modules commands but could not create one.
>
>
Does any one has any such custom script or function?
>
>
I'm looking for a script that creates a backup of a directory but keeps only
one backup.
I've tried using all the os modules commands but could not create one.
>
>
Does any one has any such custom script or function?
[http://docs.python.org/lib/module-tarfile.html] and shutil.move()
[http://docs.python.org/lib/module-shutil.html]. Just make a new
TarFile of the directory, save it, then replace any previous backup
file using shutil.move()
Good luck, and have fun!
Regards,
Chris
P.S. And if you're on *nix, you might consider just using a shell
script and the 'tar' command. Right tool for the right job and all
that.
--
Follow the path of the Iguana...