# ============================================================================ # CI:静态检查 → 单元测试 → 构建一致性 # 触发:push / pull_request(默认分支与 PR) # ============================================================================ name: CI on: push: branches: [main] pull_request: jobs: quality: name: lint + test + build runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@v4 - name: Install shellcheck run: sudo apt-get update && sudo apt-get install -y shellcheck - name: Setup Ruby (bashly) uses: ruby/setup-ruby@v1 with: ruby-version: '3.4' - name: Install bashly run: gem install bashly - name: Lint (bash -n + shellcheck) run: ./lint.sh - name: Unit tests run: ./tests/run.sh - name: Build run: ./build.sh - name: Verify artifact freshness run: ./build.sh --check