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

Method from_path

atomic-core/src/change/local.rs:86–91  ·  view source on GitHub ↗

Create a local context from a Path. # Arguments `path` - The file path `line` - The line number (1-indexed)

(path: &Path, line: u64)

Source from the content-addressed store, hash-verified

84 /// * `path` - The file path
85 /// * `line` - The line number (1-indexed)
86 pub fn from_path(path: &Path, line: u64) -> Self {
87 Self {
88 path: path.to_string_lossy().into_owned(),
89 line,
90 }
91 }
92
93 /// Get the path as a PathBuf.
94 pub fn path_buf(&self) -> PathBuf {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected