From 370e506dc9c1b0048f66b4bd23d5f0550555be0f Mon Sep 17 00:00:00 2001 From: Hajime Hoshi Date: Thu, 5 Oct 2023 02:23:51 +0900 Subject: [PATCH] .github/workflows: improve go-vet test targets --- .../{govetblock.txt => govetblock_darwin.txt} | 2 -- .github/workflows/govetblock_windows.txt | 2 ++ .github/workflows/test.yml | 15 +++++++++++++-- 3 files changed, 15 insertions(+), 4 deletions(-) rename .github/workflows/{govetblock.txt => govetblock_darwin.txt} (50%) create mode 100644 .github/workflows/govetblock_windows.txt diff --git a/.github/workflows/govetblock.txt b/.github/workflows/govetblock_darwin.txt similarity index 50% rename from .github/workflows/govetblock.txt rename to .github/workflows/govetblock_darwin.txt index 6926a0d3c..b146d6acc 100644 --- a/.github/workflows/govetblock.txt +++ b/.github/workflows/govetblock_darwin.txt @@ -1,4 +1,2 @@ github.com/hajimehoshi/ebiten/v2/internal/cocoa -github.com/hajimehoshi/ebiten/v2/internal/graphicsdriver/directx github.com/hajimehoshi/ebiten/v2/internal/graphicsdriver/metal/mtl -github.com/hajimehoshi/ebiten/v2/internal/goglfw diff --git a/.github/workflows/govetblock_windows.txt b/.github/workflows/govetblock_windows.txt new file mode 100644 index 000000000..2cd38baf7 --- /dev/null +++ b/.github/workflows/govetblock_windows.txt @@ -0,0 +1,2 @@ +github.com/hajimehoshi/ebiten/v2/internal/graphicsdriver/directx +github.com/hajimehoshi/ebiten/v2/internal/goglfw diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index b65d60fb8..ed0de1ab9 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -61,9 +61,20 @@ jobs: run: | Xvfb :99 -screen 0 1024x768x24 > /dev/null 2>&1 & - - name: go vet + - name: go vet (Linux) + if: runner.os == 'Linux' run: | - go list ./... | grep -v -x -F -f .github/workflows/govetblock.txt | xargs go vet + go vet ./... + + - name: go vet (macOS) + if: runner.os == 'macOS' + run: | + go list ./... | grep -v -x -F -f .github/workflows/govetblock_darwin.txt | xargs go vet + + - name: go vet (Windows) + if: runner.os == 'Windows' + run: | + go list ./... | grep -v -x -F -f .github/workflows/govetblock_windows.txt | xargs go vet - name: go vet (vettool) # Stop vettools for old Go versions. Apparently this is an issue in golang.org/x/tools (golang/go#62519)