From 50ed3c3952198b2c4ddc01204851a28eee1ec413 Mon Sep 17 00:00:00 2001 From: matheus Date: Tue, 6 Feb 2024 09:40:20 -0300 Subject: [PATCH] Update go to 1.21 (#20) * Update go to 1.21 * Update golangci-lint v --- .github/workflows/golangci-lint.yml | 4 ++-- .github/workflows/tests.yml | 4 ++-- Makefile | 4 ---- go.mod | 2 +- pkg/gn/gn_test.go | 2 +- 5 files changed, 6 insertions(+), 10 deletions(-) diff --git a/.github/workflows/golangci-lint.yml b/.github/workflows/golangci-lint.yml index c1da8b9..92ef1fc 100644 --- a/.github/workflows/golangci-lint.yml +++ b/.github/workflows/golangci-lint.yml @@ -15,9 +15,9 @@ jobs: steps: - uses: actions/setup-go@v3 with: - go-version: "1.18.4" + go-version: "1.21.6" - uses: actions/checkout@v3 - name: golangci-lint uses: golangci/golangci-lint-action@v3 with: - version: v1.46.2 + version: v1.55.2 diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index bf7f198..a454492 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -14,9 +14,9 @@ jobs: - uses: actions/setup-go@v2 with: - go-version: "1.18.4" + go-version: "1.21.6" - name: build run: make build - name: test - run: make test-integration \ No newline at end of file + run: make test-integration diff --git a/Makefile b/Makefile index 6749f90..9b4a0bb 100644 --- a/Makefile +++ b/Makefile @@ -20,10 +20,6 @@ fmt: # install gitnotes into /usr/local/bin # needs sudo -# TODO: consider adding this to `install`: -# ssh-keyscan -t rsa github.com > ~/.ssh/known_hosts -# ssh-keyscan -t ecdsa github.com >> ~/.ssh/known_hosts -# (may not be necessary anymore after https://github.com/go-git/go-git/issues/411 is closed) .PHONY: install install: ./dist/gn sudo cp ./dist/gn /usr/local/bin/gn diff --git a/go.mod b/go.mod index e9cacff..0a0260b 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/mcbattirola/gitnotes -go 1.18 +go 1.21 require ( github.com/go-git/go-git/v5 v5.5.2 diff --git a/pkg/gn/gn_test.go b/pkg/gn/gn_test.go index 9c06a2b..01f366d 100644 --- a/pkg/gn/gn_test.go +++ b/pkg/gn/gn_test.go @@ -33,7 +33,7 @@ func TestFindProject(t *testing.T) { // assert that find project works from a inner directory err = os.Chdir("./test") assert.NoError(t, err) - + gn.Project = "test_project" p, err = gn.findProject() assert.NoError(t, err)