gomonop/.forgejo/workflows/build.yaml

31 lines
546 B
YAML
Raw Normal View History

name: Build and test project
2024-07-19 08:51:03 +02:00
on:
push:
branches: [master]
2024-07-19 08:51:03 +02:00
pull-request:
branches: [master]
2024-07-19 08:51:03 +02:00
jobs:
build:
runs-on: debian-12
2024-07-19 08:51:03 +02:00
steps:
-
name: Checkout repo
2024-07-19 08:51:03 +02:00
uses: actions/checkout@v4
-
name: Extract Go version
id: go-version
run: |
sed '/^go /!d; s/go /version=/' go.mod >>"$GITHUB_OUTPUT"
-
name: Setup Go
2024-07-19 08:51:03 +02:00
uses: actions/setup-go@v5
with:
go-version: ${{ steps.go-version.outputs.version }}
-
name: Run tests
run: |
make test