A file in the shared folder the links point into, written with `content` when given.
(name: string, content?: string)
| 2444 | } |
| 2445 | /** A file in the shared folder the links point into, written with `content` when given. */ |
| 2446 | function sharedFile(name: string, content?: string): string { |
| 2447 | const file = path.join(tmpHome, 'dotfiles', name); |
| 2448 | fs.mkdirSync(path.dirname(file), { recursive: true }); |
| 2449 | if (content !== undefined) fs.writeFileSync(file, content); |
| 2450 | return file; |
| 2451 | } |
| 2452 | |
| 2453 | // Every file each agent's install writes, at both locations: whatever the |
| 2454 | // installer does, it never replaces or removes a link. |
no test coverage detected