mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-04-04 18:31:36 -07:00
feat(cli): Add setting to show status(or Gemini 's thoughts) in terminal title and taskbar icon (#4386)
Co-authored-by: Jacob Richman <jacob314@gmail.com> Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
This commit is contained in:
@@ -51,6 +51,7 @@ import { detectAndEnableKittyProtocol } from './ui/utils/kittyProtocolDetector.j
|
||||
import { checkForUpdates } from './ui/utils/updateCheck.js';
|
||||
import { handleAutoUpdate } from './utils/handleAutoUpdate.js';
|
||||
import { appEvents, AppEvent } from './utils/events.js';
|
||||
import { computeWindowTitle } from './utils/windowTitle.js';
|
||||
import { SettingsContext } from './ui/contexts/SettingsContext.js';
|
||||
|
||||
import { SessionStatsProvider } from './ui/contexts/SessionContext.js';
|
||||
@@ -454,13 +455,7 @@ export async function main() {
|
||||
|
||||
function setWindowTitle(title: string, settings: LoadedSettings) {
|
||||
if (!settings.merged.ui?.hideWindowTitle) {
|
||||
const windowTitle = (
|
||||
process.env['CLI_TITLE'] || `Gemini - ${title}`
|
||||
).replace(
|
||||
// eslint-disable-next-line no-control-regex
|
||||
/[\x00-\x1F\x7F]/g,
|
||||
'',
|
||||
);
|
||||
const windowTitle = computeWindowTitle(title);
|
||||
process.stdout.write(`\x1b]2;${windowTitle}\x07`);
|
||||
|
||||
process.on('exit', () => {
|
||||
|
||||
Reference in New Issue
Block a user