From 0dbde2358ce4aab9ad0fabb2b32b7a599e1211a8 Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Thu, 17 Sep 2026 12:54:32 +0200 Subject: [PATCH 1/5] ci: fix invalid workflow, and run on push, pull_request The `branches_ignore` looks to have been a typo for `branches-ignore`, but is redundant. Change the workflow to run on `push` and `pull_request` Signed-off-by: Sebastiaan van Stijn --- .github/workflows/go.yml | 2 +- .github/workflows/lint.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index 2561a16..2fce77d 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -1,8 +1,8 @@ name: build and vet on: + push: pull_request: - branches_ignore: [] jobs: build: diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 65c7ae9..ea872b0 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -1,8 +1,8 @@ name: lint on: + push: pull_request: - branches_ignore: [] jobs: lint: From 2306e72aa1df048876810feef2bf8122ebc1f89f Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Thu, 17 Sep 2026 12:56:10 +0200 Subject: [PATCH 2/5] ci: set default permissions to "contents: read" Signed-off-by: Sebastiaan van Stijn --- .github/workflows/go.yml | 3 +++ .github/workflows/lint.yml | 3 +++ 2 files changed, 6 insertions(+) diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index 2fce77d..3475206 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -4,6 +4,9 @@ on: push: pull_request: +permissions: + contents: read + jobs: build: runs-on: ubuntu-latest diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index ea872b0..a25f009 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -4,6 +4,9 @@ on: push: pull_request: +permissions: + contents: read + jobs: lint: runs-on: ubuntu-latest From a8a4c232e0acc247a2696c32115bd58bdd66e5c2 Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Thu, 17 Sep 2026 12:57:49 +0200 Subject: [PATCH 3/5] ci: update actions Update actions to a current version, to avoid failures due to deprecated NodeJS versions. Signed-off-by: Sebastiaan van Stijn --- .github/workflows/go.yml | 4 ++-- .github/workflows/lint.yml | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index 3475206..b26527e 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -17,11 +17,11 @@ jobs: name: build and vet steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v7.0.1 with: path: go/src/github.com/vbatts/tar-split - - uses: actions/setup-go@v4 + - uses: actions/setup-go@v7.0.0 with: go-version: ${{ matrix.go }} diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index a25f009..2416b7f 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -17,11 +17,11 @@ jobs: name: Linting steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v7.0.1 with: path: go/src/github.com/vbatts/tar-split - - uses: actions/setup-go@v4 + - uses: actions/setup-go@v7.0.0 with: go-version: ${{ matrix.go }} From 497942296765d49740ba922748838775632c80f3 Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Thu, 17 Sep 2026 12:50:56 +0200 Subject: [PATCH 4/5] ci: remove GOPATH This repository has a `go.mod`, so there should no longer be a need to set `GOPATH` and/or a custom working directory. Signed-off-by: Sebastiaan van Stijn --- .github/workflows/go.yml | 7 ------- .github/workflows/lint.yml | 7 ------- 2 files changed, 14 deletions(-) diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index b26527e..dfc4313 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -18,18 +18,11 @@ jobs: steps: - uses: actions/checkout@v7.0.1 - with: - path: go/src/github.com/vbatts/tar-split - - uses: actions/setup-go@v7.0.0 with: go-version: ${{ matrix.go }} - name: vet and build - env: - GOPATH: /home/runner/work/tar-split/tar-split/go run: | set -x - export PATH=$GOPATH/bin:$PATH - cd go/src/github.com/vbatts/tar-split go run mage.go -v vet build test diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 2416b7f..b821d0c 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -18,18 +18,11 @@ jobs: steps: - uses: actions/checkout@v7.0.1 - with: - path: go/src/github.com/vbatts/tar-split - - uses: actions/setup-go@v7.0.0 with: go-version: ${{ matrix.go }} - name: lint - env: - GOPATH: /home/runner/work/tar-split/tar-split/go run: | set -x - export PATH=$GOPATH/bin:$PATH - cd go/src/github.com/vbatts/tar-split go run mage.go -v lint From f9534523cec93fd80e423589509d0cb272d1a61d Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Thu, 17 Sep 2026 13:01:47 +0200 Subject: [PATCH 5/5] drop go1.22, and add go1.27 to ci Signed-off-by: Sebastiaan van Stijn --- .github/workflows/go.yml | 2 +- go.mod | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index dfc4313..a723431 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - go: ['1.22', '1.23', '1.24', '1.25', '1.26'] + go: ['1.23', '1.24', '1.25', '1.26', '1.27'] name: build and vet steps: diff --git a/go.mod b/go.mod index 1b5292c..a53820f 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/vbatts/tar-split -go 1.22.0 +go 1.23 require ( github.com/fatih/color v1.15.0