Method
write_text
(
&self,
path: &WorkspacePath,
content: &str,
)
Source from the content-addressed store, hash-verified
| 48 | } |
| 49 | |
| 50 | async fn write_text( |
| 51 | &self, |
| 52 | path: &WorkspacePath, |
| 53 | content: &str, |
| 54 | ) -> WorkspaceResult<WorkspaceWriteOutcome> { |
| 55 | self.insert(path.as_str(), content); |
| 56 | Ok(WorkspaceWriteOutcome { |
| 57 | bytes: content.len(), |
| 58 | lines: content.lines().count(), |
| 59 | }) |
| 60 | } |
| 61 | |
| 62 | async fn list_dir(&self, path: &WorkspacePath) -> WorkspaceResult<Vec<WorkspaceDirEntry>> { |
| 63 | let prefix = if path.is_root() { |
Callers
nothing calls this directly
Tested by
no test coverage detected