1
0
mirror of https://github.com/xzeldon/vwdump.git synced 2025-07-12 17:54:40 +03:00

Added backup folder

This commit is contained in:
10
2018-11-18 03:00:06 +01:00
parent 813e72c443
commit 8c380b999f
2 changed files with 7 additions and 2 deletions

View File

@ -1,8 +1,13 @@
#!/bin/sh
if [ ! -d $(dirname "$BACKUP_FILE") ]
then
mkdir -p $(dirname "$BACKUP_FILE")
fi
if [ $TIMESTAMP = true ]
then
BACKUP_FILE="$(echo $BACKUP_FILE)_$(date "+%F-%H%M%S")"
BACKUP_FILE="$(echo "$BACKUP_FILE")_$(date "+%F-%H%M%S")"
fi
/usr/bin/sqlite3 $DB_FILE ".backup $BACKUP_FILE"