MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / move_file

Method move_file

atomic-core/src/change/ops.rs:152–162  ·  view source on GitHub ↗

Creates a file move/rename operation.

(trunk_id: TrunkId, _old_path: String, new_path: String)

Source from the content-addressed store, hash-verified

150
151 /// Creates a file move/rename operation.
152 pub fn move_file(trunk_id: TrunkId, _old_path: String, new_path: String) -> Self {
153 Self {
154 trunk_id,
155 path: new_path.clone(),
156 trunk_op: Some(TrunkOp::Move {
157 trunk: trunk_id,
158 new_path,
159 }),
160 line_ops: Vec::new(),
161 }
162 }
163
164 /// Creates a file undelete operation.
165 pub fn undelete(trunk_id: TrunkId, path: String) -> Self {

Callers 1

runMethod · 0.45

Calls 1

cloneMethod · 0.45

Tested by

no test coverage detected