MCPcopy Create free account
hub / github.com/RtlZeroMemory/Rezi / walk

Function walk

scripts/run-e2e.mjs:44–55  ·  view source on GitHub ↗
(d)

Source from the content-addressed store, hash-verified

42 const out = [];
43
44 function walk(d) {
45 const entries = listDirSorted(d);
46 for (const name of entries) {
47 const full = join(d, name);
48 const st = statSync(full);
49 if (st.isDirectory()) {
50 walk(full);
51 continue;
52 }
53 if (predicate(full)) out.push(full);
54 }
55 }
56
57 walk(dir);
58 out.sort();

Callers 1

Calls 2

listDirSortedFunction · 0.70
pushMethod · 0.45

Tested by

no test coverage detected