(entries)
| 73 | } |
| 74 | |
| 75 | function saveEntries(entries) { |
| 76 | mkdirSync(CACHE_ROOT, { recursive: true }); |
| 77 | for (const entry of entries) { |
| 78 | const source = join(ROOT, entry.destination); |
| 79 | if (!existsAndHasContent(source)) { |
| 80 | log(`skip ${entry.label}; ${entry.destination} is missing`); |
| 81 | continue; |
| 82 | } |
| 83 | |
| 84 | copyIntoPlace(source, entry.cachePath, { replace: true }); |
| 85 | log(`saved ${entry.label}`); |
| 86 | } |
| 87 | } |
| 88 | |
| 89 | function printStatus(entries) { |
| 90 | console.log(`Cache root: ${CACHE_ROOT}`); |
no test coverage detected