Skip to content
Recovery

Operation Preview

Reading a plan: intent, risk level, preconditions, exact commands, checkpoint and rollback.

GitAegis
The GitAegis Operation Preview drawer for a hard reset, showing the operation's intent, a Destructive risk badge, the recovery capsule that will be taken first and what it covers, and the rollback that will be available afterwards.
The Operation Preview drawer: the intent, the risk, the capsule that will be taken before anything runs, and the way back. The exact command list sits further down the same drawer.

When it opens

Anything classified caution or destructive opens the preview and does not execute until you confirm it there. Safe plans run without it and are readable afterwards in the journal. A preview on every operation would be unusable, and an unusable safety mechanism gets clicked through. Recovery paths open it too: a Doctor repair, a capsule restore, a Flight Recorder ref restore and a Lost Work recovery all arrive as plans.

Intent and summary

The plan leads with the intent (a statement of what you are trying to achieve, not a command) followed by the planner’s plain-language summary and its working-tree implication: what happens to the files on your disk. Where a remote is involved, the remote implication is stated separately, because the two have very different reversibility.

Risk level

Classified before anything else happens. The level decides the capsule the operation takes and whether the plan must be confirmed.

Risk levels
LevelWhat it means
informationalReads the repository and changes nothing.
safeAdds a name or fetches data. Removes nothing, so no capsule is taken.
cautionReversible, but with conditions. Takes a light checkpoint.
destructiveRemoves or rewrites work. Takes a standard capsule across all six domains, and will not run without one.
blockedThe plan cannot proceed. It is shown with the reason, not executed and not queued.
The risk badge on an Operation Preview, next to the plan's intent.
Only destructive earns the danger treatment. It is a classification, not decoration.

Preconditions

Checks that must hold before anything is written: is the ref still at the oid the plan assumed, is the branch name free, does the upstream resolve, is a sequencer already in progress, does the candidate still resolve to a commit. Each is listed with its result, and the failing ones are pulled to the top of the dialog rather than buried in the details. A failed precondition blocks the plan: the confirm button is disabled and says why. That happens before the checkpoint and before any command.

The exact commands

The literal git invocations, in order, with their real arguments, in the mono face and copyable, not a paraphrase and not a category. They sit under Show full operation details, alongside the operation id, and the journal records the same argv the preview showed. Turn on expert mode in settings and they are expanded by default.

The checkpoint and the rollback plan

A caution or destructive plan states its checkpoint scope(what the capsule about to be written will cover) and then, separately, whether a rollback will be available afterwards and until when. Both are on screen while you decide, because “can I undo this?” should be answered before you press the button rather than after.

The rollback plan also lists the steps a rollback would run. Where no rollback is available the plan says so in plain terms rather than omitting the section.

Rehearsal, graded

Where Git offers a way to find out without committing, GitAegis uses it, and grades the answer rather than presenting every rehearsal as equal:

  • deterministic. The result was fully reproduced locally.
  • high: a remote’s own hooks or policies could still differ.
  • advisory: a predicted impact, not a full rehearsal.
  • unavailable. The operation cannot be rehearsed in the current state.

A rehearsal is a prediction, not a promise: it runs against the repository as it is at that moment, and a concurrent process or a moving remote can change the answer. Its stated limitations appear next to the grade.

The rest of the details

The full-details disclosure also carries the ref movements as before-and-after oids, the commits that would become unreachable (each marked if it is reachable elsewhere), the commits that would be rewritten, and the alternatives the planner considered, with the recommended one marked. These are the sections that let you decline a plan for a specific reason rather than a general unease.

30-day trial · No card required

A recovery capsule before every risky Git operation.

You see the exact commands before they run, and the operation is refused if the capsule cannot be written.

Requires Git 2.38.0 or newer, already installed.

Every risky operation, in this order

  1. Previewthe exact commands, shown before anything runs
  2. Capsulerefs, index, staged and working changes, untracked files, operation state: written to disk first
  3. Executethe commands as shown, or not at all
  4. Journalplan, commands, capsule id, outcome
No capsule, no operation. Restore plans, previews, and takes its own capsule.