fix(doctor): detect gh when Bun.which misses it

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
YeonGyu-Kim
2026-05-01 18:56:09 +09:00
parent 9c4bcebb22
commit c3beb370a5
2 changed files with 49 additions and 0 deletions
+14
View File
@@ -80,6 +80,20 @@ async function getGhAuthStatus(): Promise<{
export async function getGhCliInfo(): Promise<GhCliInfo> {
const binaryStatus = await checkBinaryExists("gh")
if (!binaryStatus.exists) {
const version = await getGhVersion()
if (version) {
const authStatus = await getGhAuthStatus()
return {
installed: true,
version,
path: null,
authenticated: authStatus.authenticated,
username: authStatus.username,
scopes: authStatus.scopes,
error: authStatus.error,
}
}
return {
installed: false,
version: null,