circumvent PATH
This commit is contained in:
@@ -36,27 +36,26 @@ fi
|
|||||||
info "Done"
|
info "Done"
|
||||||
|
|
||||||
info "Updating restic..."
|
info "Updating restic..."
|
||||||
restic self-update
|
$HOME/.local/bin/restic self-update
|
||||||
info "Done"
|
info "Done"
|
||||||
|
|
||||||
read_config
|
read_config
|
||||||
|
|
||||||
#restic -r ${RESTIC_REPOSITORY} unlock
|
restic -r ${RESTIC_REPOSITORY} unlock
|
||||||
if [[ $1 == 'prune' ]]; then
|
if [[ $1 == 'prune' ]]; then
|
||||||
info "Pruning snapshots..."
|
info "Pruning snapshots..."
|
||||||
restic --cache-dir ${CACHE_DIR} -r ${RESTIC_REPOSITORY} prune --max-unused 0
|
$HOME/.local/bin/restic --cache-dir ${CACHE_DIR} -r ${RESTIC_REPOSITORY} prune --max-unused 0
|
||||||
info "Done"
|
info "Done"
|
||||||
else
|
else
|
||||||
info "Starting backup..."
|
info "Starting backup..."
|
||||||
restic --cache-dir ${CACHE_DIR} -r ${RESTIC_REPOSITORY} backup ${BACKUP_PATHS} \
|
$HOME/.local/bin/restic --cache-dir ${CACHE_DIR} -r ${RESTIC_REPOSITORY} backup ${BACKUP_PATHS} \
|
||||||
--exclude-file ${EXCLUDES_FILE}
|
--exclude-file ${EXCLUDES_FILE}
|
||||||
info "Done"
|
info "Done"
|
||||||
|
|
||||||
info "Forgetting snapshots..."
|
info "Forgetting snapshots..."
|
||||||
restic --cache-dir ${CACHE_DIR} -r ${RESTIC_REPOSITORY} forget \
|
$HOME/.local/bin/restic --cache-dir ${CACHE_DIR} -r ${RESTIC_REPOSITORY} forget \
|
||||||
--keep-hourly ${KEEP_HOURS} --keep-daily ${KEEP_DAYS} \
|
--keep-hourly ${KEEP_HOURS} --keep-daily ${KEEP_DAYS} \
|
||||||
--keep-weekly ${KEEP_WEEKS} --keep-monthly ${KEEP_WEEKS} \
|
--keep-weekly ${KEEP_WEEKS} --keep-monthly ${KEEP_WEEKS} \
|
||||||
--keep-yearly ${KEEP_YEARS} \
|
--keep-yearly ${KEEP_YEARS} #--prune
|
||||||
--prune
|
|
||||||
info "Done"
|
info "Done"
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user