Make the --override option chainable #361

Closed
opened 2020-10-21 22:27:27 +00:00 by ClementNerma · 4 comments

Hi,

First of all thanks for making this great tool! I've used it for a bit of time now and I really enjoy its simplicity and the powerfulness of the configuration file.

I've a little suggestion for the documentation: it took me a long, very long time a few hours ago to realize that the --override argument took a list of arguments to override, instead of having to specify multiple --override ones that don't merge with each other.

This means that doing this:

$ borgmatic create --override key.a=... --override key.b=...

Is invalid and will result in only the second override clause being considered, which can be hard to debug as the documentation does not indicate how to perform multiple overrides.

So I would suggest to merge the --override arguments where multiple ones are provided to the borgmatic commands, as that's what most CLI do and is what most end users will implicitly think to.

Otherwise, I suggest to at least make the syntax clear in the documentation: if multiple items must be overriden, the following must be used:

$ borgmatic create --override key.a=... key.b=...

Thanks in advance!

Hi, First of all thanks for making this great tool! I've used it for a bit of time now and I really enjoy its simplicity and the powerfulness of the configuration file. I've a little suggestion for the documentation: it took me a long, very long time a few hours ago to realize that the `--override` argument took a list of arguments to override, instead of having to specify multiple `--override` ones that don't merge with each other. This means that doing this: ```shell $ borgmatic create --override key.a=... --override key.b=... ``` Is invalid and will result in only the second override clause being considered, which can be hard to debug as the documentation does not indicate how to perform multiple overrides. So I would suggest to merge the `--override` arguments where multiple ones are provided to the `borgmatic` commands, as that's what most CLI do and is what most end users will implicitly think to. Otherwise, I suggest to at least make the syntax clear in the documentation: if multiple items must be overriden, the following must be used: ``` $ borgmatic create --override key.a=... key.b=... ``` Thanks in advance!
Owner

Thank you so much for taking the time to report this. I totally agree.. The current behavior + documentation on this is super confusing. I'll see what I can do to improve matters.

Thank you so much for taking the time to report this. I totally agree.. The current behavior + documentation on this is super confusing. I'll see what I can do to improve matters.
Owner

Fixed in master! You can now specify --override multiple times and everything gets merged properly. I'll also update the docs when I get a chance.

Fixed in master! You can now specify `--override` multiple times and everything gets merged properly. I'll also update the docs when I get a chance.
Author

Wow that was quick!
Thanks for your amazing work :D

Wow that was quick! Thanks for your amazing work :D
Owner

Just released in borgmatic 1.5.11! (Still need to document properly.)

Just released in borgmatic 1.5.11! (Still need to document properly.)
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#361
No description provided.