ods/.forgejo/workflows/main.yaml
Julien Dessaux bc7a129321
All checks were successful
/ fmt (push) Successful in 10s
/ test (push) Successful in 11s
/ build (push) Has been skipped
chore(tooling): test forgejo actions
2025-03-13 00:19:55 +01:00

42 lines
937 B
YAML

---
on:
push:
workflow_dispatch:
jobs:
fmt:
runs-on: 'self-hosted'
steps:
- uses: 'actions/checkout@v4'
- uses: 'actions/setup-go@v5'
with:
go-version-file: 'go.mod'
- run: |
make tidy no-dirty
test:
runs-on: 'self-hosted'
steps:
- uses: 'actions/checkout@v4'
- uses: 'actions/setup-go@v5'
with:
go-version-file: 'go.mod'
- run: |
make check tidy no-dirty
build:
if: "${{ startsWith(github.ref, 'refs/tags/') }}"
needs:
- 'fmt'
- 'test'
runs-on: 'self-hosted'
steps:
- uses: 'actions/checkout@v4'
- uses: 'actions/setup-go@v5'
with:
go-version-file: 'go.mod'
- run: |
make build
- uses: 'actions/upload-artifact@v4'
with:
if-no-files-found: 'error'
name: 'ods-${{ env.GITHUB_REF_NAME }}'
path: 'ods'