Skip to content

Commit

Permalink
use gomods (#686)
Browse files Browse the repository at this point in the history
  • Loading branch information
jmank88 authored and Farber98 committed Aug 7, 2024
1 parent 23411c4 commit 8b09fef
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 11 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/pkg.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,9 @@ jobs:
- name: Ensure "make gomodtidy" has been run
run: |
make gomodtidy
git diff --exit-code
git diff --minimal --exit-code
- name: Ensure "make generate" has been run
run: |
make rm-mocked
make generate
git diff --exit-code
git diff --stat --exit-code
16 changes: 9 additions & 7 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
.PHONY: gomods
gomods: ## Install gomods
go install github.com/jmank88/[email protected]

.PHONY: gomodtidy
gomodtidy:
go mod tidy
gomodtidy: gomods
gomods tidy

.PHONY: docs
docs:
Expand All @@ -22,11 +26,9 @@ rm-mocked:
grep -rl "^// Code generated by mockery" | grep .go$ | xargs -r rm

.PHONY: generate
generate: mockery install-protoc
# add our installed protoc to the head of the PATH
# maybe there is a cleaner way to do this
PATH=$$HOME/.local/bin:$$PATH go generate -x ./...; \
mockery
generate: mockery install-protoc gomods
gomods -w go generate -x ./...
mockery

.PHONY: lint-workspace lint
GOLANGCI_LINT_VERSION := 1.55.2
Expand Down
2 changes: 0 additions & 2 deletions observability-lib/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,6 @@ github.com/spf13/cobra v1.8.0 h1:7aJaZx1B85qltLMc546zn58BxxfZdR/W22ej9CFoEf0=
github.com/spf13/cobra v1.8.0/go.mod h1:WXLWApfZ71AjXPya3WOlMsY9yMs7YeiHhFVlvLyhcho=
github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA=
github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg=
github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk=
github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo=
github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg=
github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY=
github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY=
Expand Down

0 comments on commit 8b09fef

Please sign in to comment.