Skip to content

Add Docusaurus documentation setup and update .gitignore #11

Add Docusaurus documentation setup and update .gitignore

Add Docusaurus documentation setup and update .gitignore #11

Workflow file for this run

name: CI
on:
push:
branches: [main, master]
pull_request:
branches: [main, master]
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.25'
- name: Pin toolchain (fix covdata)
run: go env -w GOTOOLCHAIN=local
- name: Run tests
run: go test -race -coverprofile=coverage.out -covermode=atomic ./...
- name: Coverage report
run: |
go tool cover -func=coverage.out
echo "## Coverage Summary" >> $GITHUB_STEP_SUMMARY
go tool cover -func=coverage.out | tail -1 >> $GITHUB_STEP_SUMMARY
- name: Upload coverage
uses: actions/upload-artifact@v4
with:
name: coverage
path: coverage.out
- name: Run vet
run: go vet ./...
- name: golangci-lint
uses: golangci/golangci-lint-action@v7
with:
version: v2.4.0
benchmark:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.25'
- name: Pin toolchain (fix covdata)
run: go env -w GOTOOLCHAIN=local
- name: Run benchmarks
run: go test -bench=. -benchmem -run=^$ ./auth/... ./permission/... 2>&1 | tee benchmark.txt
- name: Upload benchmark results
uses: actions/upload-artifact@v4
with:
name: benchmark-results
path: benchmark.txt