[Question] List files in an archive #503

Closed
opened 2022-02-24 00:36:06 +00:00 by Firesphere · 6 comments

What I'm trying to do and why

List the files in an archive

Other notes / implementation ideas

run
$ borgmatic list -a archive-name-2022-02-22-22:22

This would then output the files, just like

borg list /repository/location:name::archive-name-2022-02-22-22:22

Environment

Borgmatic version: 1.5.23

Borgmatic installation method: pip3

Borg version: 1.2.0

Python version:
pip 22.0.3 from /usr/local/lib/python3.9/dist-packages/pip (python 3.9)

operating system and version: Ubuntu 18.04.6 LTS

#### What I'm trying to do and why List the files in an archive #### Other notes / implementation ideas run $ `borgmatic list -a archive-name-2022-02-22-22:22` This would then output the files, just like `borg list /repository/location:name::archive-name-2022-02-22-22:22` #### Environment **Borgmatic version:** 1.5.23 **Borgmatic installation method:** pip3 **Borg version:** 1.2.0 **Python version:** `pip 22.0.3 from /usr/local/lib/python3.9/dist-packages/pip (python 3.9)` **operating system and version:** Ubuntu 18.04.6 LTS
Owner

Thanks for filing. This looks like a regression! It should be listing files in the given archive. I need to look into this and find out what's going on.

Thanks for filing. This looks like a regression! It *should* be listing files in the given archive. I need to look into this and find out what's going on.
Owner

Aha! Not a regression, but instead the wrong argument. Try this instead:

borgmatic list --archive archive-name-2022-02-22-22:22

The -a flag, in contrast, is the short form of --glob-archives.. which is a flag for filtering the full list of archives in a repository. But not for selecting a single archive to list. Confusing, I know.

Let me know if the --archive flag works for you!

Aha! Not a regression, but instead the wrong argument. Try this instead: ``` borgmatic list --archive archive-name-2022-02-22-22:22 ``` The `-a` flag, in contrast, is the short form of `--glob-archives`.. which is a flag for filtering the full list of archives in a repository. But not for selecting a single archive to list. Confusing, I know. Let me know if the `--archive` flag works for you!
witten added the
question / support
label 2022-02-24 05:02:11 +00:00
Author

Yep, it's indeed --archive that does exactly what I want :)

You might want to put that somewhere in the documentation? As most places, -a is documented as "a shorthand for --archive", which is in this case it isn't.

Thanks for the quick reply!

Yep, it's indeed `--archive` that does exactly what I want :) You might want to put that somewhere in the documentation? As most places, `-a` is documented as "a shorthand for `--archive`", which is in this case it isn't. Thanks for the quick reply!
Owner

Glad to hear it does what you need. Do you know of any places where -a is documented as a "a shorthand for --archive"? I'd like to fix them or let the author know to fix them. Thanks!

Glad to hear it does what you need. Do you know of any places where `-a` is documented as a "a shorthand for `--archive`"? I'd like to fix them or let the author know to fix them. Thanks!
Author

Nope, I've mixed up the Borg documentation, Borgmatic documentation and the shorthands available, and my brain turned it in to "-a should work" and got confused when it didn't.

Entirely PEBKAC! (mine, that is)

Nope, I've mixed up the Borg documentation, Borgmatic documentation and the shorthands available, and my brain turned it in to "-a should work" and got confused when it didn't. Entirely PEBKAC! (mine, that is)
Owner

Okay, no worries! I agree that -a would be intuitive!

Okay, no worries! I agree that `-a` _would_ be intuitive!
Sign in to join this conversation.
No Milestone
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: borgmatic-collective/borgmatic#503
No description provided.