Files
2026-05-02 03:55:45 +08:00

38 lines
1.1 KiB
YAML

# .github/workflows/ci.yml
# 持续集成工作流:用于代码风格检查和链接检查
name: CI
on:
workflow_dispatch:
push:
branches: [ develop, master ]
pull_request:
branches: [ develop, master ]
jobs:
markdown-lint:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
- name: Install markdownlint-cli
run: npm install -g markdownlint-cli
- name: Run markdownlint
run: markdownlint --config .github/lint_config.json --ignore .history --ignore tools/external --ignore scripts/backups/gz '**/*.md'
- name: Check local markdown links
run: python3 scripts/check-local-links.py
link-checker:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Link Checker
uses: lycheeverse/lychee-action@v1.5.0
with:
args: --verbose --no-progress --exclude-path .history --exclude-path .github/wiki --exclude-path tools/external --exclude-path tools/chat-vault --exclude-path scripts/backups/gz './**/*.md'