refactor: Improve all git operations, add stash support, add improved pull request flow, add worktree file copy options, address code review comments, add cherry pick options

This commit is contained in:
gsxdsm
2026-02-17 22:02:58 -08:00
parent f4e87d4c25
commit 9af63bc1ef
89 changed files with 6811 additions and 351 deletions

View File

@@ -144,8 +144,10 @@ export function useGeminiUsage(enabled = true) {
throw new Error('Gemini API bridge unavailable');
}
const result = await api.gemini.getUsage();
// Server always returns a response with 'authenticated' field, even on error
// So we can safely cast to GeminiUsage
// Check if result is an error-only response (no 'authenticated' field means it's the error variant)
if (!('authenticated' in result) && 'error' in result) {
throw new Error(result.message || result.error);
}
return result as GeminiUsage;
},
enabled,