diff --git a/.github/workflows/golint.yml b/.github/workflows/golint.yml new file mode 100644 index 0000000..d61fb21 --- /dev/null +++ b/.github/workflows/golint.yml @@ -0,0 +1,31 @@ +name: Go Lint + +on: + pull_request: + branches: [main] + push: + branches: + - main + workflow_dispatch: + +permissions: + contents: read + +jobs: + golint: + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v4.2.1 + with: + fetch-depth: 0 + + - name: Setup Go + uses: actions/setup-go@v5 + with: + go-version: stable + + - name: Go Lint + uses: golangci/golangci-lint-action@v6 + with: + version: v1.60 \ No newline at end of file diff --git a/.golangci.yml b/.golangci.yml new file mode 100644 index 0000000..0779746 --- /dev/null +++ b/.golangci.yml @@ -0,0 +1,10 @@ +output: + formats: + - format: colored-line-number + path: stdout + print-issued-lines: true + print-linter-name: true + sort-results: true + sort-order: + - file + - severity \ No newline at end of file