From e1cad176a2c2cc37b56b5fbf8ff52572d936bc23 Mon Sep 17 00:00:00 2001 From: mcbattirola Date: Tue, 6 Feb 2024 09:30:49 -0300 Subject: [PATCH 1/2] Update go to 1.21 --- .github/workflows/golangci-lint.yml | 2 +- .github/workflows/tests.yml | 4 ++-- Makefile | 4 ---- go.mod | 2 +- pkg/gn/gn_test.go | 2 +- 5 files changed, 5 insertions(+), 9 deletions(-) diff --git a/.github/workflows/golangci-lint.yml b/.github/workflows/golangci-lint.yml index c1da8b9..312e088 100644 --- a/.github/workflows/golangci-lint.yml +++ b/.github/workflows/golangci-lint.yml @@ -15,7 +15,7 @@ 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 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) From 7e881ee4c5e017f3fd56020557160cec00e2bba5 Mon Sep 17 00:00:00 2001 From: mcbattirola Date: Tue, 6 Feb 2024 09:35:51 -0300 Subject: [PATCH 2/2] Update golangci-lint v --- .github/workflows/golangci-lint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/golangci-lint.yml b/.github/workflows/golangci-lint.yml index 312e088..92ef1fc 100644 --- a/.github/workflows/golangci-lint.yml +++ b/.github/workflows/golangci-lint.yml @@ -20,4 +20,4 @@ jobs: - name: golangci-lint uses: golangci/golangci-lint-action@v3 with: - version: v1.46.2 + version: v1.55.2