summaryrefslogtreecommitdiff
path: root/dumps/fetch-dropbox.sh
blob: 2498be5311673f802bd165141628999c2ead1975 (plain)
1
2
3
4
5
6
7
8
#!/bin/bash
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