MCPcopy Index your code
hub / github.com/AI45Lab/Code / grep

Method grep

sdk/node/src/lib.rs:3819–3826  ·  view source on GitHub ↗
(&self, pattern: String)

Source from the content-addressed store, hash-verified

3817 /// Search file contents with a regex pattern.
3818 #[napi]
3819 pub async fn grep(&self, pattern: String) -> napi::Result<String> {
3820 let session = self.inner.clone();
3821 get_runtime()
3822 .spawn(async move { session.grep(&pattern).await })
3823 .await
3824 .map_err(|e| napi::Error::from_reason(format!("Task join error: {e}")))?
3825 .map_err(|e| napi::Error::from_reason(format!("{e}")))
3826 }
3827
3828 /// Search the web using multiple search engines.
3829 #[napi]

Callers 2

testDirectToolCallsMethod · 0.45

Calls 3

get_runtimeFunction · 0.70
cloneMethod · 0.45
spawnMethod · 0.45

Tested by

no test coverage detected