Repository navigation
Deprecate --config and add explicit SOURCE/DEST interface - #44
Merged
Merged
Conversation
Going to simplify the interface where you specify source and destination.
Going to simplify the interface where you specify source and destination.
It will still show the help for the deprecated workflow using --config/--type.
That allows to use an input variable as an output. Avoiding the use of the functions setting global `_` variables. Instead designated variables can be used directly. With that it can check if things are set or not in the function call.
Moved all commands that uses snapper to configure the source and destination. And sender and receiver. Will make it easier to clean up once the --config option is removed.
To be able to test when given SOURCE and DEST rather than --config.
To convert meson's configure_file output to something baksnapper can parse.
To make sure it fails when not given enough position arguments.
To set the key used to connect to the source/destination remote location.
To set the SOURCE/DEST private key.
Mock the ssh connection to be able to test that it works.
To be able to override source or dest from the config file.
plattfot
force-pushed
the
10/deprecate_config_option
branch
from
September 29, 2025 03:30
0b3a687 to
8dd1bd3
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Now that I finally have proper testing for this I can address the issue in #10.
Description
I'm deprecating the
--configinterface in favor of just explicitly specify the source and destination directory.Benefits for this are:
--type push/pull.snapperto be installed.Changes
--configinterface and the new.--configis not specified it not expects a positionalSOURCEandDEST--source SOURCEand--dest DEST.SOURCE=andDEST=to configure the source and backup location. Use--source/--destto override them on the CLI, or positional if overriding both.--dest-private-keyfor setting the ssh private key for the dest machine.--src-private-keyfor setting the ssh private keye for the source machine.--private-keysets the private key for both source and dest machine.Examples:
Backing up snapshots from a remote machine
Deprecated way:
New way:
Assuming the
snappersnapshot directory forhomeis/home/.snapshots.Default push backup
And for a push backup, where you have the
snappersnapshot directory forrootat/.snapshots.Deprecated way:
New way:
Backup a remote machine to another remote machine
Have a third machine pull snapshots from one remote machine and push them to another remote machine.