pub struct AdoptReport {
pub adopted: Vec<PathBuf>,
pub already_owned: Vec<PathBuf>,
pub converged: Vec<PathBuf>,
pub skipped_drifted: Vec<PathBuf>,
pub skipped_create_once: Vec<PathBuf>,
pub recorded_unstampable: Vec<PathBuf>,
pub unreadable: Vec<PathBuf>,
pub diffs: Vec<AdoptDiff>,
pub preview: bool,
}Fields§
§adopted: Vec<PathBuf>Paths whose marker (or durable ownership record) was actually written.
Always empty when write was false.
already_owned: Vec<PathBuf>Paths that already carried a marker; no diff is produced for these.
converged: Vec<PathBuf>Matches whose bytes already equal this run’s output apart from the marker.
Reported as a set of paths rather than as Self::diffs entries: their diff
is the file echoed back, so a per-file read buys the reader nothing and at
consumer-repo scale actively buries the drifted diffs that do matter. ~keep
skipped_drifted: Vec<PathBuf>Drifted matches left untouched because AdoptOptions::converged_only was set.
skipped_create_once: Vec<PathBuf>Create-once seeds excluded because AdoptOptions::clobber_create_once_seeds was
not set, in path order.
A Vec of paths rather than a count, and reported even in preview: these are the
matches where adoption is destructive, so the operator has to be able to read the
list and recognise a file as their own before deciding. A count tells them only
that something was excluded, which is exactly the fact that does not help. ~keep
recorded_unstampable: Vec<PathBuf>Paths adopted through the committed .alef-ownership.toml record because their
format cannot carry a marker at all. Reported separately from Self::adopted
because adopting these leaves the file itself byte-identical: the consent lives
in a different file, which the operator has to commit for the adoption to mean
anything anywhere else. ~keep
unreadable: Vec<PathBuf>Matches alef can make no statement about at all, in path order.
Two shapes reach this list, and both are alef failing rather than the operator
having a decision to make: bytes that are not valid UTF-8 on a path alef does not
emit as binary, and a [crate::cli::pipeline::is_base64_binary_output] path whose
generated content did not decode as base64. Skipped rather than adopted, and
reported rather than dropped – one such file used to abort the entire target: a
single gradle-wrapper.jar inside packages/** ended the run with “stream did not
contain valid UTF-8” before any of the hundreds of adoptable text files beside it
were stamped.
A jar is no longer one of them. It is classified on its decoded bytes and adopted
through the ownership record like any other unstampable format – see
BinaryFacts for why refusing it was wrong. ~keep
diffs: Vec<AdoptDiff>Full, untruncated diffs for every drifted candidate, in path order.
preview: boolTrue when this was a preview; nothing on disk was touched.
Implementations§
Trait Implementations§
Source§impl Debug for AdoptReport
impl Debug for AdoptReport
Source§impl Default for AdoptReport
impl Default for AdoptReport
Source§fn default() -> AdoptReport
fn default() -> AdoptReport
Auto Trait Implementations§
impl Freeze for AdoptReport
impl RefUnwindSafe for AdoptReport
impl Send for AdoptReport
impl Sync for AdoptReport
impl Unpin for AdoptReport
impl UnsafeUnpin for AdoptReport
impl UnwindSafe for AdoptReport
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more