Skip to content

Commit

Permalink
tell pkg.go.dev about new release when publishing
Browse files Browse the repository at this point in the history
Fixes #9
  • Loading branch information
mattrobenolt committed Feb 28, 2024
1 parent 42ec954 commit 282f67b
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
14 changes: 11 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ BIN := bin

src := main.go internal/session/session.go internal/vitess/vitess.go

ifdef DRYRUN
GORELEASERFLAGS += --snapshot
endif

all: $(BIN)/$(app)

clean: clean-bin clean-dist
Expand Down Expand Up @@ -44,7 +48,11 @@ docker:
run-mysql:
docker run -it --rm --name $(app)-mysqld -e MYSQL_ALLOW_EMPTY_PASSWORD="true" -e MYSQL_ROOT_PASSWORD="" -p 127.0.0.1:3306:3306 mysql:8.0.34

publish: clean $(BIN)/goreleaser
$(BIN)/goreleaser release
publish: $(BIN)/goreleaser
$(BIN)/goreleaser release --clean $(GORELEASERFLAGS)
$(MAKE) bump-godoc

bump-godoc:
curl -XPOST https://pkg.go.dev/fetch/$(gomod)@$(shell jq -r .tag dist/metadata.json)

.PHONY: all clean clean-bin clean-dist run docker run-mysql publish
.PHONY: all clean clean-bin clean-dist run docker run-mysql publish bump-godoc
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ require (
github.com/planetscale/psdb v0.0.0-20240109164348-6848e728f6e7
github.com/planetscale/vitess-types v0.0.0-20231211191709-770e14433716
golang.org/x/net v0.21.0
google.golang.org/protobuf v1.32.0
vitess.io/vitess v0.18.2
)

Expand Down Expand Up @@ -82,6 +81,7 @@ require (
golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20240221002015-b0ce06bbee7c // indirect
google.golang.org/grpc v1.62.0 // indirect
google.golang.org/protobuf v1.32.0 // indirect
gopkg.in/DataDog/dd-trace-go.v1 v1.60.3 // indirect
gopkg.in/ini.v1 v1.67.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
Expand Down

0 comments on commit 282f67b

Please sign in to comment.