diff --git a/CHANGELOG.md b/CHANGELOG.md index 56043dab0..06fe5f94a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -107,7 +107,7 @@ - Added `select` command. It allows to select JSON records from objects using SQL expressions. ([#299](https://github.com/peak/s5cmd/issues/299)) [@skeggse](https://github.com/skeggse) - Added `rb` command to remove buckets. ([#303](https://github.com/peak/s5cmd/issues/303)) - Added `--exclude` flag to `cp`, `rm`, `ls`, `du` and `select` commands. This flag allows users to exclude objects with given pattern. ([#266](https://github.com/peak/s5cmd/issues/266)) -- Added `--raw` flag to `cp` and `rm` commands. It disables the wildcard operations. It is useful when an object contains glob characters which interfers with glob expansion logic. ([#235](https://github.com/peak/s5cmd/issues/235)) +- Added `--raw` flag to `cp` and `rm` commands. It disables the wildcard operations. It is useful when an object contains glob characters which interferes with glob expansion logic. ([#235](https://github.com/peak/s5cmd/issues/235)) - Added `--cache-control` and `--expires` flags to `cp` and `mv` commands. It adds support for setting cache control and expires header to S3 objects. ([#318](https://github.com/peak/s5cmd/pull/318)) [@tombokombo](https://github.com/tombokombo) - Added `--force-glacier-transfer` flag to `cp` command. It forces a transfer request on all Glacier objects. ([#206](https://github.com/peak/s5cmd/issues/206)) - Added `--source-region` and `destination-region` flags to `cp` command. It allows overriding bucket region. ([#262](https://github.com/peak/s5cmd/issues/262)) [@kemege](https://github.com/kemege) diff --git a/command/auto_complete.go b/command/auto_complete.go index fe01f9495..ce48543a8 100644 --- a/command/auto_complete.go +++ b/command/auto_complete.go @@ -210,7 +210,7 @@ func formatSuggestionForShell(baseShell, suggestion, argToBeCompleted string) st return strings.Join(suggestions, "\n") case "zsh": // replace every colon : with \: if shell is zsh - // colons are used as a seperator for the autocompletion script + // colons are used as a separator for the autocompletion script // so "literal colons in completion must be quoted with a backslash" // see also https://zsh.sourceforge.io/Doc/Release/Completion-System.html#:~:text=This%20is%20followed,as%20name1%3B return strings.ReplaceAll(suggestion, ":", `\:`) diff --git a/command/error.go b/command/error.go index 37294ce4f..91e728813 100644 --- a/command/error.go +++ b/command/error.go @@ -29,7 +29,7 @@ func printDebug(op string, err error, urls ...*url.URL) { // printError is the helper function to log error messages. func printError(command, op string, err error) { - // dont print cancelation errors + // dont print cancellation errors if errorpkg.IsCancelation(err) { return } diff --git a/e2e/auto_complete_test.go b/e2e/auto_complete_test.go index a0da0cee6..4787e2bc9 100644 --- a/e2e/auto_complete_test.go +++ b/e2e/auto_complete_test.go @@ -228,7 +228,7 @@ func TestCompletionFlag(t *testing.T) { shell: "/bin/pwsh", }, /* - Question marks and asterisk are thought to be wildcard (special charactes) + Question marks and asterisk are thought to be wildcard (special characters) by the s5cmd so when they're given s5cmd's behaviour changes. When asterisk is given s5cmd also matches the keys with literal '*' as well as diff --git a/e2e/cp_test.go b/e2e/cp_test.go index 48867bd68..0e756a118 100644 --- a/e2e/cp_test.go +++ b/e2e/cp_test.go @@ -260,7 +260,7 @@ func TestCopyS3PrefixToLocalMustReturnError(t *testing.T) { assert.Assert(t, ensureS3Object(s3client, bucket, objectpath, content)) } -// cp --flatten s3://bucket/* dir/ (flat source hiearchy) +// cp --flatten s3://bucket/* dir/ (flat source hierarchy) func TestCopyMultipleFlatS3ObjectsToLocal(t *testing.T) { t.Parallel() @@ -4308,7 +4308,7 @@ func TestDeleteFileWhenDownloadFailed(t *testing.T) { assert.Assert(t, fs.Equal(cmd.Dir, expected)) } -// Target local file should be overriden only if download completed successfully +// Target local file should be overridden only if download completed successfully func TestLocalFileOverridenWhenDownloadFailed(t *testing.T) { t.Parallel() diff --git a/error/error.go b/error/error.go index e6dddfd98..3efba3878 100644 --- a/error/error.go +++ b/error/error.go @@ -39,7 +39,7 @@ func (e *Error) Unwrap() error { return e.Err } -// IsCancelation reports whether if given error is a cancelation error. +// IsCancelation reports whether if given error is a cancellation error. func IsCancelation(err error) bool { if err == nil { return false diff --git a/storage/s3.go b/storage/s3.go index f6ebcffd3..673fff8d9 100644 --- a/storage/s3.go +++ b/storage/s3.go @@ -895,7 +895,7 @@ func (s *S3) retryOnNoSuchUpload(ctx aws.Context, to *url.URL, input *s3manager. attempts := 0 for ; errHasCode(err, s3.ErrCodeNoSuchUpload) && attempts < s.noSuchUploadRetryCount; attempts++ { // check if object exists and has the retry ID we provided, if it does - // then it means that one of previous uploads was succesfull despite the received error. + // then it means that one of previous uploads was successful despite the received error. obj, sErr := s.Stat(ctx, to) if sErr == nil && obj.retryID == expectedRetryID { err = nil @@ -1400,7 +1400,7 @@ func errHasCode(err error, code string) bool { } // IsCancelationError reports whether given error is a storage related -// cancelation error. +// cancellation error. func IsCancelationError(err error) bool { return errHasCode(err, request.CanceledErrorCode) }