#!/bin/sh

# This restic-backup program wrapper supplies the options that are
# always needed for the backup operation and then calls the main
# restic via its wrapper which suppliest the needed options there.

# Copyright 2023 Bob Proulx <bob@proulx.com>
#
# Copying and distribution of this file, with or without modification,
# are permitted in any medium without royalty provided the copyright
# notice and this notice are preserved.  This file is offered as-is,
# without any warranty.
#
# Written by Bob Proulx <bob@proulx.com>

# Hints:
#
# Use "restic-wrap snapshots" to list the backup snapshots stored.
# Use "restic-wrap ls latest" to list files from the latest snapshot.
# Use "restic-wrap check" to check the file integrity of the backups.
# Use "restic-wrap restore 79766175 --target /tmp/bak" for a snap.
# Use "restic-wrap restore latest -t /tmp/bak --include foo/bar" a
# single file.

exec restic-wrap backup --exclude-file=$HOME/etc/restic/excludelist -x "$@"
