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

Function capture

atomic-cli/src/output/live.rs:60–68  ·  view source on GitHub ↗
(kind: Kind, message: &str)

Source from the content-addressed store, hash-verified

58}
59
60pub(crate) fn capture(kind: Kind, message: &str) -> bool {
61 let mut active = ACTIVE.lock().unwrap_or_else(|e| e.into_inner());
62 if let Some(state) = active.as_mut() {
63 state.capture(kind, message);
64 true
65 } else {
66 false
67 }
68}
69
70pub(crate) struct LiveOutput;
71

Calls 3

lockMethod · 0.80
into_innerMethod · 0.45
captureMethod · 0.45