Skip to content

"rsync for cloud storage" - Google Drive, S3, Dropbox, Backblaze B2, One Drive, Swift, Hubic, Wasabi, Google Cloud Storage, Azure Blob, Azure Files, Yandex Files

cat: add support for --header-download #59

Nick Craig-Wood087bf1d58422
diff --git a/fs/operations/operations.go b/fs/operations/operations.go
index 4d525459d..392401b0c 100644
--- a/fs/operations/operations.go
+++ b/fs/operations/operations.go
@@ -1296,6 +1296,9 @@ func Cat(ctx context.Context, f fs.Fs, w io.Writer, offset, count int64) error {
if opt.Start > 0 || opt.End >= 0 {
options = append(options, &opt)
}
+ for _, option := range fs.Config.DownloadHeaders {
+ options = append(options, option)
+ }
in, err := o.Open(ctx, options...)
if err != nil {
err = fs.CountError(err)