()
| 206 | } |
| 207 | |
| 208 | async function getAppInfo() { |
| 209 | const project = ctx.project |
| 210 | if (project.vcs !== "git") { |
| 211 | prompts.log.error(`Could not find git repository. Please run this command from a git repository.`) |
| 212 | throw new UI.CancelledError() |
| 213 | } |
| 214 | |
| 215 | // Get repo info |
| 216 | const info = await Effect.runPromise(gitSvc.run(["remote", "get-url", "origin"], { cwd: ctx.worktree })).then( |
| 217 | (x) => x.text().trim(), |
| 218 | ) |
| 219 | const parsed = parseGitHubRemote(info) |
| 220 | if (!parsed) { |
| 221 | prompts.log.error(`Could not find git repository. Please run this command from a git repository.`) |
| 222 | throw new UI.CancelledError() |
| 223 | } |
| 224 | return { owner: parsed.owner, repo: parsed.repo, root: ctx.worktree } |
| 225 | } |
| 226 | |
| 227 | async function promptProvider() { |
| 228 | const priority: Record<string, number> = { |
no test coverage detected