Blokovani pres konstantu
[mirrors/Programs.git] / bash / dup.sh
CommitLineData
3f0e8d9c
H
1CONF=.dup.conf
2[ -f "$CONF" ] && eval "$(cat "$CONF")" || { echo no "$CONF"; exit 23; }
3export PASSPHRASE="$DUPLICITY_PASSPHRASE";
4
5DUPLICITY_SOURCE="./"
6DUPLICITY=duplicity
7#BACKUP_TARGET="file:///tmp/bkp"
8
9case "$1" in
10 backup)
11 "$DUPLICITY" $DFLAGS "$DUPLICITY_SOURCE" "$DUPLICITY_TARGET";;
12 full)
13 "$DUPLICITY" full $DUPLICITY_FLAGS "$DUPLICITY_SOURCE" "$DUPLICITY_TARGET";;
14 verify)
15 "$DUPLICITY" verify $DUPLICITY_FLAGS "$DUPLICITY_TARGET" "$DUPLICITY_SOURCE";;
16 list)
17 "$DUPLICITY" list-current-files "$DUPLICITY_TARGET";;
18 status)
19 "$DUPLICITY" collection-status "$DUPLICITY_TARGET";;
20 cleanup)
21 "$DUPLICITY" cleanup --force "$DUPLICITY_TARGET";;
22 restore)
23 echo you can restore your files using this command:
24 echo "PASSPHRASE='$PASSPHRASE' '$DUPLICITY' restore '$DUPLICITY_TARGET' /tmp/restored";;
25 man)
26 man duplicity;;
27 *|help)
28 echo "
29 ###################################################################
30 #
31 # $0 for backing-up using duplicity
32 # --> http://duplicity.nongnu.org/
33 #
34 # $0 - same as '$0 help'
35 # $0 backup - backup (full or incremental)
36 # $0 full - full backup
37 # $0 verify - compare local files with backup
38 # $0 list - list files on backup
39 # $0 status - print backup status
40 # $0 cleanup - remove extraneous files from backup
41 # $0 restore - print command to restore files
42 # $0 help - print this help
43 # $0 man - show duplicity manpage
44 #
45";;
46esac
47
48export PASSPHRASE=''
This page took 0.12707 seconds and 4 git commands to generate.