diff --git a/pkg/cloud/aws/aws.go b/pkg/cloud/aws/aws.go index cdb46e19e..a6af3a234 100644 --- a/pkg/cloud/aws/aws.go +++ b/pkg/cloud/aws/aws.go @@ -635,7 +635,7 @@ func (c *AwsCloud) IsInstanceTypeSupported(instanceType string) (bool, error) { return slices.Contains(supportedInstanceTypes, instanceType), nil } -// GetRootVolume returns a volume IDs attached to the given which is used as a root volume +// GetRootVolumeID returns a volume IDs attached to the given which is used as a root volume func (c *AwsCloud) GetRootVolumeID(instanceID string) (string, error) { describeInstanceOutput, err := c.ec2Client.DescribeInstances(c.ctx, &ec2.DescribeInstancesInput{ InstanceIds: []string{instanceID}, diff --git a/pkg/models/host.go b/pkg/models/host.go index d275f54fc..dccf6238e 100644 --- a/pkg/models/host.go +++ b/pkg/models/host.go @@ -343,7 +343,7 @@ func (h *Host) FileExists(path string) (bool, error) { return true, nil } -// CreateTemp creates a temporary file on the remote server. +// CreateTempFile creates a temporary file on the remote server. func (h *Host) CreateTempFile() (string, error) { if !h.Connected() { if err := h.Connect(0); err != nil { diff --git a/pkg/utils/file.go b/pkg/utils/file.go index 6d5a3c4a7..a3521d92a 100644 --- a/pkg/utils/file.go +++ b/pkg/utils/file.go @@ -97,7 +97,7 @@ func WriteStringToFile(filePath string, data string) error { return os.WriteFile(filePath, []byte(data), constants.WriteReadReadPerms) } -// Size returns the size of a file or directory. +// SizeInKB returns the size of a file or directory. func SizeInKB(path string) (int64, error) { var size int64 err := filepath.Walk(path, func(_ string, info os.FileInfo, err error) error { diff --git a/pkg/utils/strings.go b/pkg/utils/strings.go index ad78d1377..501cd9170 100644 --- a/pkg/utils/strings.go +++ b/pkg/utils/strings.go @@ -23,7 +23,7 @@ func SplitComaSeparatedInt(s string) []int { }) } -// SplitString split string with a rune comma ignore quoted +// SplitStringWithQuotes split string with a rune comma ignore quoted func SplitStringWithQuotes(str string, r rune) []string { quoted := false return strings.FieldsFunc(str, func(r1 rune) bool {