docs: lead the README with the loop, not a third wordmark #7
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] | |
| pull_request: | |
| workflow_dispatch: | |
| jobs: | |
| test: | |
| name: py${{ matrix.python }} on ${{ matrix.os }} | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [ubuntu-latest, windows-latest, macos-latest] | |
| python: ["3.8", "3.12"] | |
| exclude: | |
| - os: macos-latest | |
| python: "3.8" | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - uses: actions/setup-python@v6 | |
| with: | |
| python-version: ${{ matrix.python }} | |
| - run: python -m pip install --upgrade pip | |
| - run: pip install -e ".[dev]" | |
| - name: Tests | |
| run: pytest -q | |
| - name: The CLI runs | |
| run: | | |
| substack --version | |
| substack --help | |
| lint: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - uses: actions/setup-python@v6 | |
| with: | |
| python-version: "3.12" | |
| - run: pip install ruff | |
| - run: ruff check . | |
| no-credentials: | |
| name: no credentials committed | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - name: Look for session cookies | |
| run: | | |
| if git grep -nE 's%3A[A-Za-z0-9_.%-]{30,}' -- . ':!*.yml'; then | |
| echo "A session cookie appears to be committed." | |
| exit 1 | |
| fi | |
| if git ls-files | grep -qx '.substack.json'; then | |
| echo ".substack.json is tracked and holds credentials." | |
| exit 1 | |
| fi |