Skip to content

Commit

Permalink
fix: lint warning (#557)
Browse files Browse the repository at this point in the history
* fix: lint warning

Signed-off-by: Hector Fernandez <hectorf@vmware.com>

* Fix lint warnings.

Signed-off-by: Dan Lorenc <lorenc.d@gmail.com>

Co-authored-by: Dan Lorenc <lorenc.d@gmail.com>
  • Loading branch information
Hector Fernandez and dlorenc committed Aug 22, 2021
1 parent 5267dfd commit 5c70fc4
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ linters:
- goimports
- gosec
- gocritic
- golint
- revive
- misspell
- unconvert
- unparam
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ GOLANGCI_LINT = $(shell pwd)/bin/golangci-lint
golangci-lint:
rm -f $(GOLANGCI_LINT) || :
set -e ;\
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(shell dirname $(GOLANGCI_LINT)) v1.40.1 ;\
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(shell dirname $(GOLANGCI_LINT)) v1.42.0 ;\

lint: golangci-lint ## Runs golangci-lint linter
$(GOLANGCI_LINT) run -n
Expand Down
2 changes: 1 addition & 1 deletion cmd/cosign/cli/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ import (
var (
// Output of "git describe". The prerequisite is that the branch should be
// tagged using the correct versioning strategy.
GitVersion string = "devel"
GitVersion = "devel"
// SHA1 from git, output of $(git rev-parse HEAD)
gitCommit = "unknown"
// State of git tree, either "clean" or "dirty"
Expand Down
2 changes: 1 addition & 1 deletion pkg/cosign/attestation/attestation.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ func GenerateStatement(opts GenerateOpts) (interface{}, error) {
case "link":
return generateLinkStatement(rawPayload, opts.Digest, opts.Repo)
default:
return nil, errors.New(fmt.Sprintf("we don't know this predicate type: '%s'", opts.Type))
return nil, fmt.Errorf("we don't know this predicate type: '%s'", opts.Type)
}
}

Expand Down

0 comments on commit 5c70fc4

Please sign in to comment.