From 806cc67cc18ce3bf9699e0e8aaafa61e952a5a6a Mon Sep 17 00:00:00 2001 From: emkael Date: Sat, 7 Oct 2023 23:48:51 +0200 Subject: Dropbox dump sync optional --- dumps/fetch-dropbox.sh | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/dumps/fetch-dropbox.sh b/dumps/fetch-dropbox.sh index 99db29e..2498be5 100755 --- a/dumps/fetch-dropbox.sh +++ b/dumps/fetch-dropbox.sh @@ -1,3 +1,8 @@ #!/bin/bash -dbxcli ls -l "${LIGA_DROPBOX_DUMP_FOLDER}" | awk -F"ago" '{print $2}' | sed -e 's/^[[:space:]]*//' -e 's/[[:space:]]*$//' | - xargs -I{} dbxcli get {} dumps/sync +if [ -z ${LIGA_DROPBOX_DUMP_FOLDER+x} ] +then + echo 'Dropbox dump not configured, skipping' +else + dbxcli ls -l "${LIGA_DROPBOX_DUMP_FOLDER}" | awk -F"ago" '{print $2}' | sed -e 's/^[[:space:]]*//' -e 's/[[:space:]]*$//' | + xargs -I{} dbxcli get {} dumps/sync +fi -- cgit v1.2.3