MCPcopy Create free account
hub / github.com/heygen-com/hyperframes / totalSize

Function totalSize

packages/cli/src/commands/info.ts:36–47  ·  view source on GitHub ↗
(dir: string)

Source from the content-addressed store, hash-verified

34}
35
36function totalSize(dir: string): number {
37 let total = 0;
38 for (const entry of readdirSync(dir, { withFileTypes: true })) {
39 const path = join(dir, entry.name);
40 if (entry.isDirectory()) {
41 total += totalSize(path);
42 } else {
43 total += statSync(path).size;
44 }
45 }
46 return total;
47}
48
49export default defineCommand({
50 meta: { name: "info", description: "Print project metadata" },

Callers 1

runFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected