@@define BORGCACHE root/\.cache/borg
@@define BORGCONFIG root/\.config/borg
@@define BORGBACKHOST insert-your-backup-host-here
@@define BORGBACKPATH insert-your-path-to-backup-here
/@@{BORGCACHE}(/(keys|security))?$ d VarDir
!/@@{BORGCACHE}/[[:xdigit:]]{64}$ d
!/@@{BORGCACHE}/[[:xdigit:]]{64}/(README|chunks|config|files|lock\.roster)$ f
!/@@{BORGCACHE}/[[:xdigit:]]{64}/(chunks\.archive\.d|lock\.exclusive|txn\.active)$ d
!/@@{BORGCACHE}/[[:xdigit:]]{64}/lock\.exclusive/@@{HOSTNAME}\.[[:digit:]]+\-0$ f
!/@@{BORGCACHE}/[[:xdigit:]]{64}/txn.active/(chunks|config|files)$ f
@@ifdef BORGBACKHOST
@@ifdef BORGBACKPATH
!/@@{BORGCACHE}/keys/@@{BORGBACKHOST}__@@{BORGBACKPATH}_@@{HOSTNAME}\.[[:digit:]]$ f
@@endif
@@endif
!/@@{BORGCONFIG}/security/[[:xdigit:]]{64}$ d
!/@@{BORGCONFIG}/security/[[:xdigit:]]{64}/(key-type|location|manifest-timestamp|nonce|tam_required)$ f

