Skip to content

Bump Go version and dependencies #118

Bump Go version and dependencies

Bump Go version and dependencies #118

Workflow file for this run

name: build-many
on:
push:
tags:
- 'v[0-9]+.[0-9]+.[0-9]+'
pull_request:
branches:
- '*'
jobs:
multi-os:
runs-on: ${{ matrix.os }}
defaults:
run:
shell: bash
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version: 1.22.x
- name: Cache Go packages
id: cache-go-pkgs
uses: actions/cache@v3
with:
# In order:
# * Module download cache
# * Build cache (Linux)
# * Build cache (Mac)
# * Build cache (Windows)
path: |
~/go/pkg/mod
~/.cache/go-build
~/Library/Caches/go-build
%LocalAppData%\go-build
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
- name: Get dependencies
if: steps.cache-go-pkgs.outputs.cache-hit != 'true'
run: go get
- name: Build
run: |
make release
mkdir artifact
mv lgs* artifact
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: artifact-${{ github.sha }}-${{ matrix.os }}
path: artifact
retention-days: 1
docker:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Build image
run: docker build -t lgs .