()
| 40 | } |
| 41 | |
| 42 | function findLocalBinary(): string { |
| 43 | const projectRoot = resolve(import.meta.dir, '../..') |
| 44 | const distPath = resolve(projectRoot, 'dist/cli.js') |
| 45 | if (existsSync(distPath)) return distPath |
| 46 | |
| 47 | const devPath = resolve(projectRoot, 'src/entrypoints/cli.tsx') |
| 48 | if (existsSync(devPath)) return devPath |
| 49 | |
| 50 | throw new Error( |
| 51 | 'Cannot find local CLI binary to deploy. Run `bun run build` first.', |
| 52 | ) |
| 53 | } |
| 54 | |
| 55 | export async function deployBinary(options: DeployOptions): Promise<string> { |
| 56 | const { host, remotePlatform, remoteArch, localVersion, onProgress } = options |
no test coverage detected