MCPcopy Create free account
hub / github.com/SteffMet/tabby-vscode-agent / copyRecursive

Function copyRecursive

scripts/prepare-publish.js:12–25  ·  view source on GitHub ↗
(src, dest)

Source from the content-addressed store, hash-verified

10
11// Helper function to copy files/directories
12function copyRecursive(src, dest) {
13 const stat = fs.statSync(src);
14 if (stat.isDirectory()) {
15 if (!fs.existsSync(dest)) {
16 fs.mkdirSync(dest, { recursive: true });
17 }
18 const items = fs.readdirSync(src);
19 items.forEach(item => {
20 copyRecursive(path.join(src, item), path.join(dest, item));
21 });
22 } else {
23 fs.copyFileSync(src, dest);
24 }
25}
26
27function prepare() {
28 console.log('🚀 Starting publish preparation...');

Callers 1

prepareFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected