Bump golangci/golangci-lint-action from 3 to 6 #10
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
jobs: | |
lint: | |
name: Lint | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version: '1.23.0' | |
cache: false | |
- name: golangci-lint | |
uses: golangci/golangci-lint-action@v6 | |
with: | |
version: latest | |
args: --timeout=10m --out-format=colored-line-number | |
test: | |
name: Test | |
strategy: | |
matrix: | |
os: [ubuntu-latest, macos-latest, windows-latest] | |
arch: [amd64, 386] | |
exclude: | |
- os: macos-latest | |
arch: 386 | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install 386 dependencies on Ubuntu | |
if: matrix.arch == '386' && matrix.os == 'ubuntu-latest' | |
run: | | |
sudo dpkg --add-architecture i386 | |
sudo apt-get update | |
sudo apt-get install -y gcc-multilib libc6-dev-i386 | |
- name: Setup Windows Build Environment | |
if: matrix.arch == '386' && matrix.os == 'windows-latest' | |
uses: msys2/setup-msys2@v2 | |
with: | |
msystem: MINGW32 | |
update: true | |
install: >- | |
mingw-w64-i686-gcc | |
mingw-w64-i686-make | |
mingw-w64-i686-toolchain | |
path-type: inherit | |
- name: Configure Build Environment | |
if: matrix.arch == '386' && matrix.os == 'windows-latest' | |
shell: msys2 {0} | |
run: | | |
echo "CC=D:/a/_temp/msys64/mingw32/bin/gcc.exe" >> $GITHUB_ENV | |
echo "D:/a/_temp/msys64/mingw32/bin" >> $GITHUB_PATH | |
- uses: actions/setup-go@v5 | |
with: | |
go-version: '1.23.0' | |
cache: false | |
architecture: ${{ matrix.arch }} | |
- name: Run tests | |
run: make test |