mirror of
https://github.com/LukeHagar/theschemagen.git
synced 2025-12-06 04:21:44 +00:00
62 lines
1.2 KiB
YAML
62 lines
1.2 KiB
YAML
name: CI
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
pull_request:
|
|
|
|
permissions:
|
|
contents: write
|
|
packages: write
|
|
pull-requests: write
|
|
|
|
env:
|
|
GO_VERSION: 1.21.3
|
|
APP_NAME: theschemagen
|
|
|
|
jobs:
|
|
lint:
|
|
name: Lint
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
|
|
|
|
- name: Setup Go
|
|
uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5
|
|
with:
|
|
go-version: ${{ env.GO_VERSION }}
|
|
|
|
- name: Install Dependencies
|
|
run: go mod download
|
|
|
|
- name: Verify Dependencies
|
|
run: go mod verify
|
|
|
|
- name: Lint ${{ env.APP_NAME }}
|
|
run: go vet ./...
|
|
|
|
test:
|
|
name: Test
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
|
|
|
|
- name: Setup Go
|
|
uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5
|
|
with:
|
|
go-version: ${{ env.GO_VERSION }}
|
|
|
|
- name: Install Dependencies
|
|
run: go mod download
|
|
|
|
- name: Verify Dependencies
|
|
run: go mod verify
|
|
|
|
- name: Test ${{ env.APP_NAME }}
|
|
run: go test -v ./...
|