(options: CopyOptions)
| 47 | platform?: NodeJS.Platform |
| 48 | } |
| 49 | function copy(options: CopyOptions) { |
| 50 | const { fromRootDir, toRootDir, packagerName, platform = process.platform } = options |
| 51 | |
| 52 | const fromTargets = targets({ rootDir: fromRootDir, packagerName, platform }) |
| 53 | const toTargets = targets({ rootDir: toRootDir, packagerName, platform }) |
| 54 | |
| 55 | return Promise.all( |
| 56 | fromTargets.map((from, index) => { |
| 57 | const to = toTargets[index] |
| 58 | if (from.type === "dir") { |
| 59 | dir(from.path) |
| 60 | } |
| 61 | |
| 62 | return filesystem.copyAsync(from.path, to.path, { overwrite: true }) |
| 63 | }), |
| 64 | ) |
| 65 | } |
| 66 | |
| 67 | // Root directory path of ignite dependency cache |
| 68 | function rootdir(platform: NodeJS.Platform = process.platform) { |
no test coverage detected