When mounting a full repo with borg2 mount, the top-level directories are currently named {name}-{id}.
This makes sense because archive names are no longer unique in borg2, but using the archive ID (aid) isn't very user-friendly. It's just a hash, so if one wants to mount or inspect one or more specific archives, one first has to run borg2 repo-list to figure out which aid belongs to which archive. This is a bit cumbersome.
This only affects mounting the whole repo. Mounting a single archive or a specific path isn't affected.
I'd like to propose two possible alternative approaches:
-
Use a better hardcoded directory name format.
We could discuss which metadata is most useful and include that in the directory name. I think the archive start time is probably the most useful addition, so something like {name}-{id}-{start} would already make things much easier. WDYT?
-
Make the directory name format configurable.
Add an option (I'd probably prefer a mount option over a CLI option) that lets users define the directory name format themselves, using the same placeholders that are already supported by commands like borg2 repo-list.
The default could stay {name}-{id}, or it could switch to something like {name}-{id}-{start}.
When mounting a full repo with
borg2 mount, the top-level directories are currently named{name}-{id}.This makes sense because archive names are no longer unique in
borg2, but using the archive ID (aid) isn't very user-friendly. It's just a hash, so if one wants to mount or inspect one or more specific archives, one first has to runborg2 repo-listto figure out whichaidbelongs to which archive. This is a bit cumbersome.This only affects mounting the whole repo. Mounting a single archive or a specific path isn't affected.
I'd like to propose two possible alternative approaches:
Use a better hardcoded directory name format.
We could discuss which metadata is most useful and include that in the directory name. I think the archive start time is probably the most useful addition, so something like
{name}-{id}-{start}would already make things much easier. WDYT?Make the directory name format configurable.
Add an option (I'd probably prefer a mount option over a CLI option) that lets users define the directory name format themselves, using the same placeholders that are already supported by commands like
borg2 repo-list.The default could stay
{name}-{id}, or it could switch to something like{name}-{id}-{start}.