From 84b2bd76f71dfbf3b270c07a47e813758529a585 Mon Sep 17 00:00:00 2001 From: Abhinav Gupta Date: Sat, 30 Nov 2024 10:56:59 -0800 Subject: [PATCH] Upgrade to Go 1.23 Upgrade to Go 1.23, change CI to use go.mod for Go version. --- .github/workflows/ci.yml | 12 +++--------- .github/workflows/docs.yml | 7 +++---- .github/workflows/release.yml | 3 +-- go.mod | 2 +- integration/go.mod | 2 +- 5 files changed, 9 insertions(+), 17 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e05112c..48a96be 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -6,9 +6,6 @@ on: pull_request: branches: [ '*' ] -env: - GO_VERSION: 1.22.x - jobs: lint: @@ -20,8 +17,7 @@ jobs: - uses: actions/setup-go@v5 name: Set up Go with: - go-version: ${{ env.GO_VERSION }} - cache: false + go-version-file: go.mod - uses: golangci/golangci-lint-action@v6 name: Install golangci-lint with: @@ -41,8 +37,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v5 with: - go-version: ${{ env.GO_VERSION }} - cache: true + go-version-file: go.mod - name: Test run: make cover @@ -61,8 +56,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v5 with: - go-version: ${{ env.GO_VERSION }} - cache: true + go-version-file: go.mod # Node is needed to download pagefind. - name: Set up Node diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index f309ec1..9b51203 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -18,8 +18,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v5 with: - go-version: 1.22.x - cache: true + go-version-file: go.mod - name: Set up Node uses: actions/setup-node@v4 with: @@ -31,7 +30,7 @@ jobs: - name: Setup Hugo uses: peaceiris/actions-hugo@v3 with: - hugo-version: '0.123.4' + hugo-version: '0.139.3' extended: true - name: Build @@ -51,7 +50,7 @@ jobs: id-token: write environment: name: github-pages - url: ${{ steps.deployment.output.pages_url }} + url: ${{ steps.deployment.outputs.page_url }} runs-on: ubuntu-latest steps: diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 1a973a6..ca4fa83 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -27,8 +27,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v5 with: - go-version: 1.22.x - cache: true + go-version-file: go.mod - name: Install parse-changelog uses: taiki-e/install-action@v2 diff --git a/go.mod b/go.mod index 06cc038..bb3095d 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module go.abhg.dev/doc2go -go 1.22.0 +go 1.23 require ( braces.dev/errtrace v0.3.0 diff --git a/integration/go.mod b/integration/go.mod index 6e99090..282643e 100644 --- a/integration/go.mod +++ b/integration/go.mod @@ -1,6 +1,6 @@ module go.abhg.dev/doc2go/integration -go 1.22.0 +go 1.23 replace go.abhg.dev/doc2go => ../