[Bug] source_directories_must_exist does not expand globs and tildes #682
Loading…
x
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What I'm trying to do and why
I am trying to add
source_directories_must_exist: true
to my existing Borgmatic config so I can make use of this feature. However I any directories with globs or tildes are not being expanded and always fail the existence check.Steps to reproduce (if a bug)
Add source directories with globs and tildes while enabling
source_directories_must_exist
.Example config file:
Removing
source_directories_must_exist
resolves the issue.Actual behavior (if a bug)
Expected behavior (if a bug)
A successful backup of source directories containing globs and tildes, as was the case before adding
source_directories_must_exist
.Other notes / implementation ideas
Seems no expansion is being done during the existence check.
so should be a simple matter to fix:
Happy to open a pull request to fix and add a unit test.
Environment
borgmatic version: 1.7.12
Use
sudo borgmatic --version
orsudo pip show borgmatic | grep ^Version
borgmatic installation method: pip
Borg version: 1.2.1
Use
sudo borg --version
Python version: 3.10.6
Use
python3 --version
Database version (if applicable): n/a
Use
psql --version
ormysql --version
on client and server.operating system and version: Ubuntu 22.04.2
Good catch! I think your analysis is completely correct here. And yes, I'd welcome a PR if you're up to it.
This was just released in borgmatic 1.7.13!