feat: add explicit license selection and status visibility (#6751)

This commit is contained in:
jason 2025-08-23 05:01:01 +09:00 committed by GitHub
parent bb8a23ae80
commit 5030ced9e1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
13 changed files with 382 additions and 40 deletions

View file

@ -27,11 +27,18 @@ export const aboutCommand: SlashCommand = {
const cliVersion = await getCliVersion();
const selectedAuthType =
context.services.settings.merged.selectedAuthType || '';
const gcpProject = process.env['GOOGLE_CLOUD_PROJECT'] || '';
// Only show GCP Project for auth types that actually use it
const gcpProject =
selectedAuthType === 'oauth-gca' ||
selectedAuthType === 'vertex-ai' ||
selectedAuthType === 'cloud-shell'
? process.env['GOOGLE_CLOUD_PROJECT'] || ''
: '';
const ideClient =
(context.services.config?.getIdeMode() &&
context.services.config?.getIdeClient()?.getDetectedIdeDisplayName()) ||
'';
const userTier = context.services.config?.getGeminiClient()?.getUserTier();
const aboutItem: Omit<HistoryItemAbout, 'id'> = {
type: MessageType.ABOUT,
@ -42,6 +49,7 @@ export const aboutCommand: SlashCommand = {
selectedAuthType,
gcpProject,
ideClient,
userTier,
};
context.ui.addItem(aboutItem, Date.now());