Skip to content

Commit

Permalink
gofumpt
Browse files Browse the repository at this point in the history
Co-Authored-By: Christopher Hunter <[email protected]>
  • Loading branch information
2 people authored and pvaramballypivot committed Oct 3, 2024
1 parent dba1aa1 commit e589cc1
Show file tree
Hide file tree
Showing 6 changed files with 4 additions and 8 deletions.
2 changes: 0 additions & 2 deletions internal/commands/update_release.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@ func (u UpdateRelease) Execute(args []string) error {
StemcellOS: kilnfileLock.Stemcell.OS,
GitHubRepository: releaseSpec.GitHubRepository,
}, false)

if err != nil {
if component.IsErrNotFound(err) {
return fmt.Errorf("error finding the release: %w", err)
Expand All @@ -99,7 +98,6 @@ func (u UpdateRelease) Execute(args []string) error {
StemcellVersion: kilnfileLock.Stemcell.Version,
GitHubRepository: releaseSpec.GitHubRepository,
})

if err != nil {
if component.IsErrNotFound(err) {
return fmt.Errorf("error finding the release: %w", err)
Expand Down
1 change: 0 additions & 1 deletion internal/commands/update_stemcell.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ func (update UpdateStemcell) Execute(args []string) error {

kilnStemcellVersion := kilnfile.Stemcell.Version
releaseVersionConstraint, err = semver.NewConstraint(kilnStemcellVersion)

if err != nil {
return fmt.Errorf("invalid stemcell constraint in kilnfile: %w", err)
}
Expand Down
3 changes: 2 additions & 1 deletion pkg/cargo/validate.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@ package cargo

import (
"fmt"
"github.com/Masterminds/semver/v3"
"slices"
"text/template/parse"

"github.com/Masterminds/semver/v3"
)

type ValidationOptions struct {
Expand Down
3 changes: 2 additions & 1 deletion pkg/cargo/validate_test.go
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
package cargo

import (
"github.com/stretchr/testify/require"
"testing"

"github.com/stretchr/testify/require"

. "github.com/onsi/gomega"

"github.com/stretchr/testify/assert"
Expand Down
1 change: 0 additions & 1 deletion pkg/planitest/internal/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ func MergeAdditionalProductProperties(configFile io.Reader, additionalProperties

var inputConfig ProductConfiguration
err = yaml.Unmarshal(yamlInput, &inputConfig)

if err != nil {
return nil, fmt.Errorf("could not parse config file: %s", err)
}
Expand Down
2 changes: 0 additions & 2 deletions pkg/planitest/internal/om_runner.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@ func (o OMRunner) ResetAndConfigure(productName string, productVersion string, c
"--product-name", productName,
"--product-version", productVersion,
)

if err != nil {
return fmt.Errorf("Unable to stage product %q, version %q: %s: %s",
productName, productVersion, err, errOutput)
Expand All @@ -114,7 +113,6 @@ func (o OMRunner) ResetAndConfigure(productName string, productVersion string, c
"configure-product",
"--config", configFile.Name(),
)

if err != nil {
return fmt.Errorf("Unable to configure product %q: %s: %s", productName, err, errOutput)
}
Expand Down

0 comments on commit e589cc1

Please sign in to comment.