-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Reduce permissions for GITHUB_TOKEN issued during build * Remove "go get" for downloading dependencies, as the build step will do this automatically for Go module projects * Upgrade minimum Go version from 1.13 to 1.16 * Fix phony targets in Makefile (.PHONEY -> .PHONY)
- Loading branch information
1 parent
144302e
commit d8a2747
Showing
5 changed files
with
62 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,42 +1,42 @@ | ||
current_dir = $(shell pwd) | ||
|
||
.PHONEY: lint | ||
.PHONY: lint | ||
lint: | ||
golangci-lint run ./... | ||
|
||
.PHONEY: build | ||
.PHONY: build | ||
build: | ||
go build -o gomodguard cmd/gomodguard/main.go | ||
|
||
.PHONEY: run | ||
.PHONY: run | ||
run: build | ||
./gomodguard | ||
|
||
.PHONEY: test | ||
.PHONY: test | ||
test: | ||
go test -v -coverprofile coverage.out | ||
|
||
.PHONEY: cover | ||
.PHONY: cover | ||
cover: | ||
gocover-cobertura < coverage.out > coverage.xml | ||
|
||
.PHONEY: dockerrun | ||
.PHONY: dockerrun | ||
dockerrun: dockerbuild | ||
docker run -v "${current_dir}/.gomodguard.yaml:/.gomodguard.yaml" ryancurrah/gomodguard:latest | ||
|
||
.PHONEY: release | ||
.PHONY: release | ||
release: | ||
goreleaser --rm-dist | ||
|
||
.PHONEY: clean | ||
.PHONY: clean | ||
clean: | ||
rm -rf dist/ | ||
rm -f gomodguard coverage.xml coverage.out | ||
|
||
.PHONEY: install-tools-mac | ||
.PHONY: install-tools-mac | ||
install-tools-mac: | ||
brew install goreleaser/tap/goreleaser | ||
|
||
.PHONEY: install-go-tools | ||
.PHONY: install-go-tools | ||
install-go-tools: | ||
go get github.com/t-yuki/gocover-cobertura |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
module github.com/ryancurrah/gomodguard | ||
|
||
go 1.14 | ||
go 1.16 | ||
|
||
require ( | ||
github.com/Masterminds/semver v1.5.0 | ||
|