Skip to content

chore: add golang-ci #10

chore: add golang-ci

chore: add golang-ci #10

name: Continuous Integration
on:
workflow_dispatch:
push:
pull_request:
jobs:
check-app:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: 1.22.6
- name: Install golangci-lint
run: |
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.54.2
- name: Run golangci-lint
run: golangci-lint run --out-format=line-number > golangci-lint-report.txt || true
continue-on-error: true
- name: golangci-lint
uses: reviewdog/action-golangci-lint@v2
with:
reporter: github-pr-review
golangci_lint_flags: "--enable-all --exclude-use-default=false"
github_token: ${{ secrets.GITHUB_TOKEN }}