ZeroBot-Plugin/.github/workflows/push.yml
源文雨 1c8ff7b143
Some checks failed
最新版 / Build binary CI (386, linux) (push) Has been cancelled
最新版 / Build binary CI (386, windows) (push) Has been cancelled
最新版 / Build binary CI (amd64, linux) (push) Has been cancelled
最新版 / Build binary CI (amd64, windows) (push) Has been cancelled
最新版 / Build binary CI (arm, linux) (push) Has been cancelled
最新版 / Build binary CI (arm64, linux) (push) Has been cancelled
自动更新 nix 依赖 / gomod2nix update (push) Has been cancelled
PushLint / lint (push) Has been cancelled
fix(aichat): possible panic when save mem err
2026-01-28 21:33:41 +08:00

48 lines
1.2 KiB
YAML

name: PushLint
on:
push:
branches:
- master
jobs:
golangci:
name: lint
runs-on: ubuntu-latest
steps:
- name: Set up Go
uses: actions/setup-go@master
with:
go-version: '1.25'
- name: Check out code into the Go module directory
uses: actions/checkout@master
with:
ref: master
fetch-depth: 0
submodules: 'recursive'
- name: Prepare Necessary Runtime Files
run: |
go generate main.go
go mod tidy
- name: Run Lint
uses: golangci/golangci-lint-action@master
with:
version: latest
- name: Commit back
if: ${{ !github.head_ref }}
continue-on-error: true
run: |
git config --local user.name 'github-actions[bot]'
git config --local user.email '41898282+github-actions[bot]@users.noreply.github.com'
git add --all
git commit -m "chore(lint): 改进代码样式"
- name: Create Pull Request
if: ${{ !github.head_ref }}
continue-on-error: true
uses: peter-evans/create-pull-request@v8
with:
title: "chore(lint): 改进代码样式"