Re: [Evolution] Creating a backup script
- From: Ron Johnson <ron l johnson cox net>
- To: Evolution ML <evolution ximian com>
- Subject: Re: [Evolution] Creating a backup script
- Date: Tue, 20 Apr 2004 02:14:46 -0500
On Tue, 2004-04-20 at 02:49 -0400, Andrew Conkling wrote:
I've made a backup script to be executed in my crontab, but it's a bit
dirty and I'd appreciate it if anyone could help me clean it up a bit.
I've added comments to indicate what I'd like to do with it (i.e. where
my scripting skills are inadequate):
#!/bin/bash
evolution-1.5 --force-shutdown
Hey, that's clever. I wonder if it will cause all instances of Evo
to die, if run by root?
export TIME=`clock` # This spits out a lot of time info; I'd like to
make this a bit terser
$ x=`date +%y%m%d.%H%M` # great for timestamping files
$ echo $x
040420.0204
$ stime=`date +"%F %R"` # nice and human readable
$ echo $stime
2004-04-20 02:04
tar
-cfz /home/andrew/.evolution_files_$TIME.tar.gz /home/andrew/.evolution/*
Try this instead:
cd ~andrew
$ x=`date +%y%m%d.%H%M` # great for timestamping files
tar cfj evolution_files_${x}.tar.bz2 \
--recursion \
--exclude=.evolution/cache/http \
--exclude=.evolution/imap \
.evolution
--
Ron Johnson <ron l johnson cox net>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]