| 273 | } |
| 274 | |
| 275 | export function copyFolderSync(source: string, target: string): void { |
| 276 | if (!fs.existsSync(target)) { |
| 277 | fs.mkdirSync(target, {recursive: true}); |
| 278 | } |
| 279 | |
| 280 | fs.readdirSync(source).forEach((item) => { |
| 281 | const sourcePath = path.join(source, item); |
| 282 | const targetPath = path.join(target, item); |
| 283 | |
| 284 | if (fs.lstatSync(sourcePath).isDirectory()) { |
| 285 | copyFolderSync(sourcePath, targetPath); |
| 286 | } else { |
| 287 | fs.copyFileSync(sourcePath, targetPath); |
| 288 | } |
| 289 | }); |
| 290 | } |
| 291 | |
| 292 | export function defaultMultiChainYamlManifestPath(projectPath: string): string { |
| 293 | return path.join(projectPath, DEFAULT_MULTICHAIN_MANIFEST); |