Skip to content

Merge pull request #1 from ayushedith/feature/ci-and-ai #2

Merge pull request #1 from ayushedith/feature/ci-and-ai

Merge pull request #1 from ayushedith/feature/ci-and-ai #2

Workflow file for this run

name: CI
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: '1.25'
- name: Cache Go modules
uses: actions/cache@v4
with:
path: |
~/.cache/go-build
~/.cache/golangci-lint
${{ github.workspace }}/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
- name: Install golangci-lint
uses: golangci/golangci-lint-action@v4
with:
version: v1.59.0
- name: Go fmt check
run: |
go fmt ./...
- name: Go vet
run: go vet ./...
- name: Run tests
run: go test ./... -v
- name: Run golangci-lint
run: golangci-lint run --out-format=github-actions