pub struct WorkspaceDiffResult {
pub base_branch: Option<String>,
pub changes: Vec<WorkspaceDiffFileChange>,
pub is_fallback: bool,
pub mode: WorkspaceDiffMode,
pub requested_mode: WorkspaceDiffMode,
pub unavailable_reason: Option<HistoryRewindUnavailableReason>,
}Expand description
Workspace diff result for the requested mode.
Experimental. This type is part of an experimental wire-protocol surface and may change or be removed in future SDK or CLI releases.
Fields§
§base_branch: Option<String>Default branch used for a branch diff, when branch mode was requested.
changes: Vec<WorkspaceDiffFileChange>Changed files and their unified diffs.
is_fallback: boolWhether the requested diff fell back to unstaged changes, either because branch diff failed or session diff was unavailable.
mode: WorkspaceDiffModeEffective mode used for the returned changes.
requested_mode: WorkspaceDiffModeDiff mode requested by the client.
Why the session diff could not be produced, when applicable. Set only when session mode was requested and isFallback is true, so a client can tell the permanent file-change-tracking-disabled apart from the transient session-busy, which the same request answers once the session settles. Never set for unstaged or branch mode, and never unsupported-remote-session: a remote session’s captures live on its own host, so a session-mode diff is rejected for one rather than answered with a controller-side fallback.
Trait Implementations§
Source§impl Clone for WorkspaceDiffResult
impl Clone for WorkspaceDiffResult
Source§fn clone(&self) -> WorkspaceDiffResult
fn clone(&self) -> WorkspaceDiffResult
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more