Skip to content
This repository has been archived by the owner on Nov 19, 2024. It is now read-only.

Add ArchiveAsync; context no longer optional #320

Merged
merged 1 commit into from
Mar 1, 2022
Merged

Conversation

mholt
Copy link
Owner

@mholt mholt commented Feb 9, 2022

Motivated by rclone/rclone#2815.

Allows creating an archive by sending files down a channel rather than needing to pre-build a list of all the files up front. This is useful for efficiently creating an archive when reading a sequential stream. I think.

Following Go best-practices.

Zip and Tar now support ArchiveAsync, which reads files from a channel
instead of a slice.
@mholt
Copy link
Owner Author

mholt commented Mar 1, 2022

Merging, as the feedback from @ncw out-of-band is "That interface looks perfect and exactly what rclone needs" -- we can tweak it later if needed.

@mholt mholt merged commit 2efff02 into master Mar 1, 2022
@mholt mholt deleted the archive-from-stream branch March 1, 2022 21:16
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant