Skip to content
This repository was archived by the owner on Nov 11, 2026. It is now read-only.

Merge pull request #60 from systemfsoftware/chore/remove-macos #4

Merge pull request #60 from systemfsoftware/chore/remove-macos

Merge pull request #60 from systemfsoftware/chore/remove-macos #4

Workflow file for this run

name: Rust
on:
push:
branches: [ "main", "dev" ]
pull_request:
branches: [ "main", "dev" ]
workflow_dispatch:
permissions:
contents: read
concurrency:
group: rust-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
CARGO_TERM_COLOR: always
# Build gitcomet in headless mode (no GPUI system deps required).
# The UI-only code paths are behind #[cfg(feature = "ui-gpui")] guards.
APP_FEATURES: "--no-default-features --features gix"
jobs:
fmt:
name: Rustfmt
runs-on: ubuntu-22.04
timeout-minutes: 60
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@4360b52568e2003a75bf9bc1d59f33a8e3fc893c # stable
with:
components: rustfmt
- name: Cache Rust artifacts
uses: Swatinem/rust-cache@49a0bdc70d2e1b713ca9e2869b211fcce03d3c1c # v2
- name: Check formatting
run: cargo fmt --all --check
audit:
name: Dependency audit (cargo-audit)
runs-on: ubuntu-22.04
timeout-minutes: 60
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@4360b52568e2003a75bf9bc1d59f33a8e3fc893c # stable
- name: Cache Rust artifacts
uses: Swatinem/rust-cache@49a0bdc70d2e1b713ca9e2869b211fcce03d3c1c # v2
- name: Install cargo-audit
run: cargo install cargo-audit --locked
- name: Run cargo-audit
run: |
IGNORES=(
RUSTSEC-2025-0052 # unmaintained-status advisory: async-std discontinued; transitive only, no CVE/exploit path (verified via rustsec.org 2026-08-16)
RUSTSEC-2024-0384 # unmaintained-status advisory: crate instant (unmaintained; transitive)
RUSTSEC-2024-0436 # unmaintained-status advisory: crate paste (unmaintained; transitive)
RUSTSEC-2025-0134 # unmaintained-status advisory: crate rustls-pemfile (unmaintained; transitive)
)
cargo audit "${IGNORES[@]/#/--ignore }"
clippy:
name: Clippy
runs-on: ubuntu-22.04
timeout-minutes: 60
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@4360b52568e2003a75bf9bc1d59f33a8e3fc893c # stable
- name: Cache Rust artifacts
uses: Swatinem/rust-cache@49a0bdc70d2e1b713ca9e2869b211fcce03d3c1c # v2
- name: Clippy (core + state + git backends)
run: cargo clippy -p gitcomet-core -p gitcomet-state -p gitcomet-git -p gitcomet-git-gix -- -D warnings
- name: Clippy (GPUI UI crate -- intentionally skipped on headless CI)
run: |
echo "Skipping cargo clippy -p gitcomet-ui-gpui in this job."
echo "Reason: GPUI requires native windowing/system dependencies that are not available in headless CI."
- name: Clippy (app — headless)
run: cargo clippy -p gitcomet $APP_FEATURES -- -D warnings
build:
name: Build
runs-on: ubuntu-22.04
timeout-minutes: 60
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@4360b52568e2003a75bf9bc1d59f33a8e3fc893c # stable
- name: Cache Rust artifacts
uses: Swatinem/rust-cache@49a0bdc70d2e1b713ca9e2869b211fcce03d3c1c # v2
- name: Build (core + state + backend)
run: cargo build -p gitcomet-core -p gitcomet-state -p gitcomet-git-gix --verbose
- name: Build (app — headless)
run: cargo build -p gitcomet $APP_FEATURES --verbose
# Core merge algorithm correctness — Phase 1A/1B/1C portability tests
merge-algorithm:
name: Merge algorithm parity (t6403/t6427)
runs-on: ubuntu-22.04
timeout-minutes: 60
needs: build
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@4360b52568e2003a75bf9bc1d59f33a8e3fc893c # stable
- name: Cache Rust artifacts
uses: Swatinem/rust-cache@49a0bdc70d2e1b713ca9e2869b211fcce03d3c1c # v2
- name: t6403/t6427 merge algorithm portability
run: cargo test -p gitcomet-core --test merge_algorithm --verbose
- name: Conflict label formatting (Phase 1C)
run: cargo test -p gitcomet-core --test conflict_label_formatting --verbose
- name: Meld algorithm parity (Phase 5)
run: cargo test -p gitcomet-core --lib meld_tests --verbose
- name: Core library unit tests
run: cargo test -p gitcomet-core --lib --verbose
- name: State management (conflict session, reducers, effects)
run: cargo test -p gitcomet-state --verbose
# Fixture harness and corpus — Phase 2/3A regression gates
merge-regression:
name: Merge regression suite (fixtures + corpus)
runs-on: ubuntu-22.04
timeout-minutes: 60
needs: build
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@4360b52568e2003a75bf9bc1d59f33a8e3fc893c # stable
- name: Cache Rust artifacts
uses: Swatinem/rust-cache@49a0bdc70d2e1b713ca9e2869b211fcce03d3c1c # v2
- name: KDiff3-style fixture harness (Phase 2)
run: cargo test -p gitcomet-core --test merge_fixture_harness --verbose
- name: Permutation corpus (Phase 3A — 243 sampled cases)
run: cargo test -p gitcomet-core --test merge_permutation_corpus --verbose
- name: Real-world merge extraction (Phase 3C)
run: cargo test -p gitcomet-core --test merge_git_extraction --verbose
# E2E integration with git mergetool/difftool — Phase 4A/4B
tool-integration:
name: Git mergetool/difftool E2E parity
runs-on: ubuntu-22.04
timeout-minutes: 60
needs: build
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@4360b52568e2003a75bf9bc1d59f33a8e3fc893c # stable
- name: Cache Rust artifacts
uses: Swatinem/rust-cache@49a0bdc70d2e1b713ca9e2869b211fcce03d3c1c # v2
- name: Build gitcomet binary (headless)
run: cargo build -p gitcomet $APP_FEATURES
- name: Git mergetool E2E (Phase 4A — t7610 parity)
run: cargo test -p gitcomet $APP_FEATURES --test mergetool_git_integration --verbose
- name: Git difftool E2E (Phase 4B — t7800 parity)
run: cargo test -p gitcomet $APP_FEATURES --test difftool_git_integration --verbose
- name: Standalone tool-mode E2E (exit codes + validation)
run: cargo test -p gitcomet $APP_FEATURES --test standalone_tool_mode_integration --verbose
- name: Mergetool/difftool runtime unit tests (bin target)
run: cargo test -p gitcomet $APP_FEATURES --bin gitcomet --verbose
# Backend integration — mergetool launcher, status, conflict checkout
backend-integration:
name: Git backend integration
runs-on: ubuntu-22.04
timeout-minutes: 60
needs: build
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@4360b52568e2003a75bf9bc1d59f33a8e3fc893c # stable
- name: Cache Rust artifacts
uses: Swatinem/rust-cache@49a0bdc70d2e1b713ca9e2869b211fcce03d3c1c # v2
- name: Git CLI migration scoreboard
run: cargo test -p gitcomet-git-gix --test git_cli_scoreboard -- --nocapture
- name: Status and mergetool backend integration
run: cargo test -p gitcomet-git-gix --verbose