pub enum Change {
None,
Add {
id: Option<String>,
uri: Option<String>,
flake: bool,
},
Remove {
ids: Vec<ChangeId>,
},
Change {
id: Option<String>,
uri: Option<String>,
ref_or_rev: Option<String>,
},
Follows {
input: ChangeId,
target: String,
},
}Variants§
None
Add
Remove
Change
Follows
Add a follows relationship to an input.
Example: flake-edit follow rust-overlay.nixpkgs nixpkgs
Creates: rust-overlay.inputs.nixpkgs.follows = "nixpkgs";
Implementations§
Source§impl Change
impl Change
pub fn id(&self) -> Option<ChangeId>
pub fn ids(&self) -> Vec<ChangeId>
pub fn is_remove(&self) -> bool
pub fn is_some(&self) -> bool
pub fn is_add(&self) -> bool
pub fn is_change(&self) -> bool
pub fn is_follows(&self) -> bool
pub fn uri(&self) -> Option<&String>
pub fn follows_target(&self) -> Option<&String>
pub fn success_messages(&self) -> Vec<String>
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Change
impl<'de> Deserialize<'de> for Change
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for Change
impl RefUnwindSafe for Change
impl Send for Change
impl Sync for Change
impl Unpin for Change
impl UnwindSafe for Change
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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>
Converts
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>
Converts
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