mirror of
https://github.com/nabbar/golib.git
synced 2025-10-27 17:51:12 +08:00
Package AWS:
- rework MultipartUpload process & helper - update test to use lib size - update object multipart to use new helper Package IO Utils : - add truncate & sync to FileProgress - fix error on open file mode for FileProgress Package Console : - fix interface used for color buffer Package Cobra : - add function to print message on write config to use custom message instead of internal message. If the function is not set, the default message will be print. Other: - fix golangci-lint config to remove crazy linter (use only golang group compliance linter) - bump dependencies
This commit is contained in:
@@ -31,6 +31,7 @@ import (
|
||||
"crypto/rand"
|
||||
"errors"
|
||||
"fmt"
|
||||
libsiz "github.com/nabbar/golib/size"
|
||||
"io/ioutil"
|
||||
"net"
|
||||
"net/http"
|
||||
@@ -240,8 +241,8 @@ func WaitMinio(host string) bool {
|
||||
return err == nil
|
||||
}
|
||||
|
||||
func randContent(size int) *bytes.Buffer {
|
||||
p := make([]byte, size)
|
||||
func randContent(size libsiz.Size) *bytes.Buffer {
|
||||
p := make([]byte, size.Int64())
|
||||
|
||||
_, err := rand.Read(p)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user