feat: add graceful KeyboardInterrupt handling in commit generation #17
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: [main, develop] | |
| pull_request: | |
| branches: [main, develop] | |
| jobs: | |
| lint: | |
| runs-on: ubuntu-latest | |
| # 跳过 auto-release 产生的 commit | |
| if: "!contains(github.event.head_commit.message, '[skip-ci]')" | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.11" | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install -e ".[dev]" | |
| - name: Run black | |
| run: black --check src/ | |
| - name: Run mypy | |
| run: mypy src/ | |
| continue-on-error: true | |
| test: | |
| runs-on: ${{ matrix.os }} | |
| # 跳过 auto-release 产生的 commit | |
| if: "!contains(github.event.head_commit.message, '[skip-ci]')" | |
| strategy: | |
| matrix: | |
| os: [ubuntu-latest, macos-latest, windows-latest] | |
| python-version: ["3.10", "3.11", "3.12"] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install -e . | |
| - name: Test installation | |
| run: | | |
| claude-commit --help |