Skip to content

Commit

Permalink
Create lint.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
lvmingze123 authored Oct 11, 2024
1 parent e0dee16 commit 5b4a213
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Lint Code

on:
push:
branches:
- main
pull_request:
branches:
- main

jobs:
lint:
runs-on: ubuntu-latest

steps:
- name: Check out code
uses: actions/checkout@v2

- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: '1.20'

- 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.49.0
- name: Run golangci-lint
run: golangci-lint run ./...

0 comments on commit 5b4a213

Please sign in to comment.