-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Suspicious calling code for rclone backend #1896
Comments
I've taken an initial pass at this. Opening PR. |
Thank you very much for your contribution. Can we please discuss the changes first, and then break them down into manageable work items? I don't have so much time for code review right now (for a bit of background see the forum). |
I've taken a look, we should make sure that the Let me know if you need any help, and thanks for taking care of this issue! |
This properly issues the initial repository creation command Fixes restic#1896
This properly issues the initial repository creation command Fixes restic#1896
This properly issues the initial repository creation command Fixes restic#1896
https://github.com/restic/restic/blob/master/cmd/restic/global.go#L652
rclone.Open
is called here instead ofrclone.Create
This additionally means that
rclone.Create
is unused code (except for tests).rclone.Open
andrclone.Create
contain almost identical code. The main difference is thatrclone.Create
callsrest.Create
andrclone.Open
callsrest.Open
.There are a few other minor discrepancies that should probably be resolved (e.g., via a common helper function): https://github.com/restic/restic/blob/master/internal/backend/rclone/backend.go#L254 vs https://github.com/restic/restic/blob/master/internal/backend/rclone/backend.go#L282 and https://github.com/restic/restic/blob/master/internal/backend/rclone/backend.go#L260 vs https://github.com/restic/restic/blob/master/internal/backend/rclone/backend.go#L288
@fd0
The text was updated successfully, but these errors were encountered: