feat(cli): one command to update submodules to tracked branch tips #53
Workflow file for this run
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
| # gitxtend CI — gates every PR to main. | |
| # | |
| # HOOK PARITY: this pipeline is mirrored by .githooks/pre-push. When editing the | |
| # steps here, update the hook to match (and vice-versa). | |
| # PUBLISH PIPELINE: .github/workflows/publish.yml fires on vX.Y.Z tags and uploads | |
| # abi3 manylinux/macOS/Windows wheels + an sdist to PyPI. It is NOT mirrored by the | |
| # pre-push hook (uploading to PyPI is a release gate only). | |
| name: ci | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| env: | |
| CARGO_TERM_COLOR: always | |
| jobs: | |
| check: | |
| name: fmt + clippy + test (core) + build (python) | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| with: | |
| components: rustfmt, clippy | |
| - uses: Swatinem/rust-cache@v2 | |
| - name: rustfmt | |
| run: cargo fmt --all --check | |
| # The pure-Rust core (no PyO3 / no libpython): the M1 read methods live here. | |
| - name: clippy (core) | |
| run: cargo clippy --no-default-features --all-targets -- -D warnings | |
| - name: test (core) | |
| run: cargo test --no-default-features | |
| # The PyO3 wheel surface. `extension-module` links no libpython, so it | |
| # builds on CI without python-dev. | |
| - name: clippy (python) | |
| run: cargo clippy --features extension-module -- -D warnings | |
| - name: build (python) | |
| run: cargo build --features extension-module | |
| python-e2e: | |
| name: maturin build + Python E2E vs git | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| - uses: Swatinem/rust-cache@v2 | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.12" | |
| # The standalone CLI, needed by the front-end parity test (it runs the | |
| # binary and the console script over the same argv and compares). Without | |
| # it that test would SKIP locally — and `CI` being set turns the skip into | |
| # a failure, so this step is load-bearing, not a convenience. | |
| - name: build the standalone CLI | |
| run: cargo build --release --bin gitxtend | |
| - name: build wheel + run the E2E suite (the compiled module vs the real git CLI) | |
| env: | |
| CI: "1" | |
| run: | | |
| python -m venv .venv | |
| .venv/bin/pip install -q maturin | |
| .venv/bin/maturin develop --release --extras dev | |
| .venv/bin/python -m pytest python/tests/ --cov=gitxtend --cov-fail-under=80 |