Skip to content

Commit

Permalink
update packages etc (#24)
Browse files Browse the repository at this point in the history
* update packages etc

Signed-off-by: kouki <kouworld0123@gmail.com>
  • Loading branch information
kmdkuk committed Jul 5, 2022
1 parent 56535b0 commit 0da9e1c
Show file tree
Hide file tree
Showing 7 changed files with 109 additions and 194 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,15 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
fetch-depth: 1
- name: Setup Go
uses: actions/setup-go@v2
uses: actions/setup-go@v3
with:
go-version: 1.16.5
go-version: 1.18
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v2
uses: goreleaser/goreleaser-action@v3
with:
version: latest
args: release --rm-dist
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/test_and_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,15 +24,15 @@ jobs:
- windows-latest
steps:
- name: setup go
uses: actions/setup-go@v2
uses: actions/setup-go@v3
with:
go-version: 1.16.5
go-version: 1.18
- name: checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
fetch-depth: 1
- name: cache
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
Expand Down
2 changes: 1 addition & 1 deletion .tool-versions
Original file line number Diff line number Diff line change
@@ -1 +1 @@
golang 1.16.5
golang 1.18.3
11 changes: 9 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,10 @@ GO_LDFLAGS := -X github.com/kmdkuk/git-push-notifier/version.BuildDate=$(BUILD_D
DEV_LDFLAGS := $(GO_LDFLAGS)
GO_LDFLAGS := -X github.com/kmdkuk/git-push-notifier/version.Version=$(VERSION) $(GO_LDFLAGS)

# Test tools
BIN_DIR := $(shell pwd)/bin
GOLANGCI_LINT := $(BIN_DIR)/golangci-lint

bin/git-push-notifier: $(BUILD_FILES)
go build -trimpath -ldflags "$(GO_LDFLAGS)" -o "$@" .

Expand All @@ -41,10 +45,13 @@ test:
go tool cover -html=coverage.txt -o coverage.html
.PHONY: test

lint:
golangci-lint run ./...
lint: $(GOLANGCI_LINT)
$(GOLANGCI_LINT) run ./...
.PHONY: lint

profile:
go tool pprof -http="localhost:8080" bin/git-push-notifier cpu.pprof
.PHONY: profile

$(GOLANGCI_LINT):
GOBIN=$(BIN_DIR) go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest
35 changes: 28 additions & 7 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,13 +1,34 @@
module github.com/kmdkuk/git-push-notifier

go 1.14
go 1.18

require (
github.com/kr/text v0.2.0 // indirect
github.com/mitchellh/go-homedir v1.1.0
github.com/spf13/cobra v1.2.1
github.com/spf13/viper v1.8.1
golang.org/x/sync v0.0.0-20210220032951-036812b2e83c
golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c // indirect
github.com/spf13/cobra v1.5.0
github.com/spf13/viper v1.12.0
golang.org/x/sync v0.0.0-20220601150217-0de741cfad7f
golang.org/x/xerrors v0.0.0-20220609144429-65e65417b02f
)

require (
github.com/fsnotify/fsnotify v1.5.4 // indirect
github.com/hashicorp/hcl v1.0.0 // indirect
github.com/inconshreveable/mousetrap v1.0.0 // indirect
github.com/magiconair/properties v1.8.6 // indirect
github.com/mitchellh/mapstructure v1.5.0 // indirect
github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e // indirect
github.com/pelletier/go-toml v1.9.5 // indirect
github.com/pelletier/go-toml/v2 v2.0.1 // indirect
github.com/rogpeppe/go-internal v1.8.1 // indirect
github.com/spf13/afero v1.8.2 // indirect
github.com/spf13/cast v1.5.0 // indirect
github.com/spf13/jwalterweatherman v1.1.0 // indirect
github.com/spf13/pflag v1.0.5 // indirect
github.com/subosito/gotenv v1.3.0 // indirect
golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a // indirect
golang.org/x/text v0.3.7 // indirect
gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f // indirect
gopkg.in/ini.v1 v1.66.4 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.0 // indirect
)
Loading

0 comments on commit 0da9e1c

Please sign in to comment.