Implement the Git workflow and replace Git placeholders #16

Closed
opened 2026-07-18 20:45:57 +00:00 by hugo · 1 comment
Owner

Goal

Deliver the Git extension as one working vertical slice over project files, including repository inspection, local commits, remote synchronization, reconciliation, and the desktop UI.

Current state

  • Site, media, translation, and metadata validation already work.
  • The Git sidebar, Git log panel, and Git diff tab are placeholders in crates/bds-ui.
  • There is no Rust Git engine.
  • specs/git.allium and the GitDiffSurface in specs/editor_misc.allium are normative.

Required behavior

  • Inspect and initialize the active project's repository, including the expected .gitignore and Git LFS image tracking.
  • Return file status, staged/unstaged and per-file diffs, branch history, rename-following file history, origin URL, upstream branch, and ahead/behind counts.
  • Add or update origin; commit all changes while rejecting blank messages.
  • Fetch, fast-forward-only pull, and push with live output and cancellation.
  • Run Git non-interactively, terminate local operations after 15 seconds and network operations after 120 seconds, and turn authentication failures into structured provider/platform guidance.
  • Gate fetch, pull, and push while airplane mode is active; keep inspection and commits available.
  • After pull, reconcile changed posts, scripts, and templates through the normal rebuild/filesystem paths and emit domain events.
  • Replace the Git sidebar, log panel, and diff placeholders with localized working views.

Implementation notes

  • Read docs/UI_STYLE_GUIDE.md before UI work.
  • Prefer the installed git executable and the existing task/output infrastructure; do not add a second repository model.
  • Reuse metadata diff and rebuild engines for reconciliation.
  • Follow red/green TDD and use ../bDS2/lib/bds/git.ex plus its stream/UI tests when the specs are silent.

Acceptance criteria

  • Status, diff, history, remote state, commit, fetch, pull, push, cancellation, timeout, auth-error, LFS, reconciliation, and airplane-mode paths have tests.
  • Added/deleted files render with an empty missing side, and file history follows renames with the specified limit.
  • Pull cannot create a merge commit.
  • All three Git placeholders are gone and every action is reachable from the UI.
  • Filesystem metadata, metadata diff, and rebuild remain consistent after reconciliation.
  • allium check specs, cargo fmt --all -- --check, cargo build --workspace, and cargo test --workspace pass.
## Goal Deliver the Git extension as one working vertical slice over project files, including repository inspection, local commits, remote synchronization, reconciliation, and the desktop UI. ## Current state - Site, media, translation, and metadata validation already work. - The Git sidebar, Git log panel, and Git diff tab are placeholders in crates/bds-ui. - There is no Rust Git engine. - specs/git.allium and the GitDiffSurface in specs/editor_misc.allium are normative. ## Required behavior - Inspect and initialize the active project's repository, including the expected .gitignore and Git LFS image tracking. - Return file status, staged/unstaged and per-file diffs, branch history, rename-following file history, origin URL, upstream branch, and ahead/behind counts. - Add or update origin; commit all changes while rejecting blank messages. - Fetch, fast-forward-only pull, and push with live output and cancellation. - Run Git non-interactively, terminate local operations after 15 seconds and network operations after 120 seconds, and turn authentication failures into structured provider/platform guidance. - Gate fetch, pull, and push while airplane mode is active; keep inspection and commits available. - After pull, reconcile changed posts, scripts, and templates through the normal rebuild/filesystem paths and emit domain events. - Replace the Git sidebar, log panel, and diff placeholders with localized working views. ## Implementation notes - Read docs/UI_STYLE_GUIDE.md before UI work. - Prefer the installed git executable and the existing task/output infrastructure; do not add a second repository model. - Reuse metadata diff and rebuild engines for reconciliation. - Follow red/green TDD and use ../bDS2/lib/bds/git.ex plus its stream/UI tests when the specs are silent. ## Acceptance criteria - Status, diff, history, remote state, commit, fetch, pull, push, cancellation, timeout, auth-error, LFS, reconciliation, and airplane-mode paths have tests. - Added/deleted files render with an empty missing side, and file history follows renames with the specified limit. - Pull cannot create a merge commit. - All three Git placeholders are gone and every action is reachable from the UI. - Filesystem metadata, metadata diff, and rebuild remain consistent after reconciliation. - allium check specs, cargo fmt --all -- --check, cargo build --workspace, and cargo test --workspace pass.
hugo added the enhancement label 2026-07-18 20:45:57 +00:00
Author
Owner

Implemented in commit 422f71c and pushed to main. This adds the complete Git engine and localized UI workflow: repository/LFS setup, status and diffs, branch and rename-following file history, remotes and ahead/behind state, commits, cancellable fetch/fast-forward-only pull/push with live output, airplane-mode gating, structured authentication guidance, and post-pull reconciliation for posts, scripts, and templates through normal rebuild paths and typed events. Verification passed: cargo test --workspace, cargo clippy --workspace --all-targets -- -D warnings, cargo build --workspace, cargo fmt --all -- --check, and Allium check/analyse.

Implemented in commit 422f71c and pushed to main. This adds the complete Git engine and localized UI workflow: repository/LFS setup, status and diffs, branch and rename-following file history, remotes and ahead/behind state, commits, cancellable fetch/fast-forward-only pull/push with live output, airplane-mode gating, structured authentication guidance, and post-pull reconciliation for posts, scripts, and templates through normal rebuild paths and typed events. Verification passed: cargo test --workspace, cargo clippy --workspace --all-targets -- -D warnings, cargo build --workspace, cargo fmt --all -- --check, and Allium check/analyse.
hugo closed this issue 2026-07-19 09:53:51 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: hugo/RuDS#16