pub struct Changeset {
pub proc: Option<Arc<DaggerSessionProc>>,
pub selection: Selection,
pub graphql_client: DynGraphQLClient,
}Fields§
§proc: Option<Arc<DaggerSessionProc>>§selection: Selection§graphql_client: DynGraphQLClientImplementations§
Source§impl Changeset
impl Changeset
Sourcepub async fn added_paths(&self) -> Result<Vec<String>, DaggerError>
pub async fn added_paths(&self) -> Result<Vec<String>, DaggerError>
Files and directories that were added in the newer directory.
Sourcepub async fn diff_stats(&self) -> Result<Vec<DiffStat>, DaggerError>
pub async fn diff_stats(&self) -> Result<Vec<DiffStat>, DaggerError>
Structured per-path diff statistics (kind and line counts) for this changeset.
Sourcepub async fn export(
&self,
path: impl Into<String>,
) -> Result<String, DaggerError>
pub async fn export( &self, path: impl Into<String>, ) -> Result<String, DaggerError>
Applies the diff represented by this changeset to a path on the host.
§Arguments
path- Location of the copied directory (e.g., “logs/”).
Sourcepub async fn id(&self) -> Result<Id, DaggerError>
pub async fn id(&self) -> Result<Id, DaggerError>
A unique identifier for this Changeset.
Sourcepub async fn is_empty(&self) -> Result<bool, DaggerError>
pub async fn is_empty(&self) -> Result<bool, DaggerError>
Returns true if the changeset is empty (i.e. there are no changes).
Sourcepub fn layer(&self) -> Directory
pub fn layer(&self) -> Directory
Return a snapshot containing only the created and modified files
Sourcepub async fn modified_paths(&self) -> Result<Vec<String>, DaggerError>
pub async fn modified_paths(&self) -> Result<Vec<String>, DaggerError>
Files and directories that existed before and were updated in the newer directory.
Sourcepub async fn removed_paths(&self) -> Result<Vec<String>, DaggerError>
pub async fn removed_paths(&self) -> Result<Vec<String>, DaggerError>
Files and directories that were removed. Directories are indicated by a trailing slash, and their child paths are not included.
Sourcepub async fn sync(&self) -> Result<Changeset, DaggerError>
pub async fn sync(&self) -> Result<Changeset, DaggerError>
Force evaluation in the engine.
Sourcepub fn with_changeset(&self, changes: impl IntoID<Id>) -> Changeset
pub fn with_changeset(&self, changes: impl IntoID<Id>) -> Changeset
Add changes to an existing changeset By default the operation will fail in case of conflicts, for instance a file modified in both changesets. The behavior can be adjusted using onConflict argument
§Arguments
changes- Changes to merge into the actual changesetopt- optional argument, see inner type for documentation, use_opts to use
Sourcepub fn with_changeset_opts(
&self,
changes: impl IntoID<Id>,
opts: ChangesetWithChangesetOpts,
) -> Changeset
pub fn with_changeset_opts( &self, changes: impl IntoID<Id>, opts: ChangesetWithChangesetOpts, ) -> Changeset
Add changes to an existing changeset By default the operation will fail in case of conflicts, for instance a file modified in both changesets. The behavior can be adjusted using onConflict argument
§Arguments
changes- Changes to merge into the actual changesetopt- optional argument, see inner type for documentation, use_opts to use
Sourcepub fn with_changesets(&self, changes: Vec<Id>) -> Changeset
pub fn with_changesets(&self, changes: Vec<Id>) -> Changeset
Add changes from multiple changesets using git octopus merge strategy This is more efficient than chaining multiple withChangeset calls when merging many changesets. Only FAIL and FAIL_EARLY conflict strategies are supported (octopus merge cannot use -X ours/theirs).
§Arguments
changes- List of changesets to merge into the actual changesetopt- optional argument, see inner type for documentation, use_opts to use
Sourcepub fn with_changesets_opts(
&self,
changes: Vec<Id>,
opts: ChangesetWithChangesetsOpts,
) -> Changeset
pub fn with_changesets_opts( &self, changes: Vec<Id>, opts: ChangesetWithChangesetsOpts, ) -> Changeset
Add changes from multiple changesets using git octopus merge strategy This is more efficient than chaining multiple withChangeset calls when merging many changesets. Only FAIL and FAIL_EARLY conflict strategies are supported (octopus merge cannot use -X ours/theirs).
§Arguments
changes- List of changesets to merge into the actual changesetopt- optional argument, see inner type for documentation, use_opts to use
Trait Implementations§
Source§impl Exportable for Changeset
impl Exportable for Changeset
Source§impl Loadable for Changeset
impl Loadable for Changeset
Source§fn graphql_type() -> &'static str
fn graphql_type() -> &'static str
"Container").Source§fn from_query(
proc: Option<Arc<DaggerSessionProc>>,
selection: Selection,
graphql_client: DynGraphQLClient,
) -> Self
fn from_query( proc: Option<Arc<DaggerSessionProc>>, selection: Selection, graphql_client: DynGraphQLClient, ) -> Self
Auto Trait Implementations§
impl !RefUnwindSafe for Changeset
impl !UnwindSafe for Changeset
impl Freeze for Changeset
impl Send for Changeset
impl Sync for Changeset
impl Unpin for Changeset
impl UnsafeUnpin for Changeset
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
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> ⓘ
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