From 0c52c7e2b604f15c67a0ae127704e7c4d5848a1b Mon Sep 17 00:00:00 2001 From: tomsmeding Date: Thu, 23 Nov 2017 20:47:40 +0100 Subject: Add backupfiles.sh script (only zelfoverhoor now) --- backupfiles.sh | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100755 backupfiles.sh diff --git a/backupfiles.sh b/backupfiles.sh new file mode 100755 index 0000000..97d4860 --- /dev/null +++ b/backupfiles.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +test "$(hostname)" = "tomsmeding.com" || { echo "Not on server...?"; exit 1; } +cp --version >/dev/null 2>&1 || { echo "not GNU cp"; exit 1; } +cd ~/webserver +mkdir -p ../backups_webserver +find modules/zelfoverhoor -type f -name '*.json' | grep -v 'accounts.json' | xargs cp -v -t ../backups_webserver -- cgit v1.2.3-70-g09d2