feat(git): build and run the source control write operations

Adds the three pieces ops.rs was missing: GitOp::commands, the pure argv
table every write goes through; run_op, which executes those batches and
turns a failure into something the UI can act on; and classify, which
reads git's own words to decide what the failure was.

Pathspecs always carry :(literal) and always sit after a --, so a file
named a[b].txt, HEAD or -f names itself. Long lists split at 200 paths.
Non-UTF-8 paths are rejected up front rather than sent lossily.

The old command spellings throughout, never git restore, so one argv
works on a CentOS 7 dev box and here alike; the only state-dependent
branch is an unborn HEAD, and HeadState is a parameter so the table
stays pure.
This commit is contained in:
l0ng-ai
2026-08-09 00:26:10 +08:00
parent 3b3e5fa046
commit bb9208cf3e
File diff suppressed because it is too large Load Diff