feat: use email-based profile IDs for OAuth providers
Changes writeOAuthCredentials and applyAuthProfileConfig calls to use the email from OAuth response as part of the profile ID instead of hardcoded ":default". This enables multiple accounts per provider - each login creates a separate profile (e.g., google-antigravity:user@gmail.com) instead of overwriting the same :default profile. Affected files: - src/commands/onboard-auth.ts (generic writeOAuthCredentials) - src/commands/configure.ts (Antigravity flow) - src/wizard/onboarding.ts (Antigravity flow)
This commit is contained in:
@@ -462,7 +462,7 @@ export async function runOnboardingWizard(
|
||||
if (oauthCreds) {
|
||||
await writeOAuthCredentials("google-antigravity", oauthCreds);
|
||||
nextConfig = applyAuthProfileConfig(nextConfig, {
|
||||
profileId: "google-antigravity:default",
|
||||
profileId: `google-antigravity:${oauthCreds.email ?? "default"}`,
|
||||
provider: "google-antigravity",
|
||||
mode: "oauth",
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user