(entrypoint: string, dest: string)
| 714 | } |
| 715 | |
| 716 | async function copyEntrypoint(entrypoint: string, dest: string): Promise<void> { |
| 717 | const data = await readFile(entrypoint, 'utf8'); |
| 718 | |
| 719 | // Modify package to `package main` |
| 720 | const patched = data.replace(/\bpackage\W+\S+\b/, 'package main'); |
| 721 | |
| 722 | await writeFile(join(dest, 'entrypoint.go'), patched); |
| 723 | } |
| 724 | |
| 725 | async function copyDevServer( |
| 726 | functionName: string, |
no test coverage detected