From c13b860c763a56fc8b97dbb2e35e7c6f3b950f2c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ahmet=20Hakan=20Be=C5=9Fel?= Date: Mon, 10 Jun 2024 15:50:57 +0300 Subject: [PATCH] command/pipe: update `pipe` file compression example (#708) Closes #704 Replaced ```bash tar -cf - file.bin | s5cmd pipe s3://bucket/file.bin.tar ``` with ```bash gzip -c file | s5cmd pipe s3://bucket/file.gz ``` Why? - Less flags, less confusing - To be consistent with the other examples --- README.md | 2 +- command/pipe.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 2ec990177..7b12cbf7d 100644 --- a/README.md +++ b/README.md @@ -268,7 +268,7 @@ You can upload remote objects by piping stdin to `s5cmd`: Or you can compress the data before uploading: - tar -cf - file.bin | s5cmd pipe s3://bucket/file.bin.tar + gzip -c file | s5cmd pipe s3://bucket/file.gz #### Delete an S3 object diff --git a/command/pipe.go b/command/pipe.go index 77793f7bc..14a0f9251 100644 --- a/command/pipe.go +++ b/command/pipe.go @@ -34,7 +34,7 @@ Examples: 03. Download an object and stream it to a bucket > curl https://github.com/peak/s5cmd/ | s5cmd {{.HelpName}} s3://bucket/s5cmd.html 04. Compress an object and stream it to a bucket - > tar -cf - file.bin | s5cmd {{.HelpName}} s3://bucket/file.bin.tar + > gzip -c file | s5cmd {{.HelpName}} s3://bucket/file.gz ` func NewPipeCommandFlags() []cli.Flag {