mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-04-09 21:00:56 -07:00
Update error codes when process exiting the gemini cli (#13728)
This commit is contained in:
@@ -14,7 +14,8 @@ import {
|
||||
} from '../../config/trustedFolders.js';
|
||||
import * as process from 'node:process';
|
||||
import { type HistoryItemWithoutId, MessageType } from '../types.js';
|
||||
import { coreEvents } from '@google/gemini-cli-core';
|
||||
import { coreEvents, ExitCodes } from '@google/gemini-cli-core';
|
||||
import { runExitCleanup } from '../../utils/cleanup.js';
|
||||
|
||||
export const useFolderTrust = (
|
||||
settings: LoadedSettings,
|
||||
@@ -75,8 +76,9 @@ export const useFolderTrust = (
|
||||
'error',
|
||||
'Failed to save trust settings. Exiting Gemini CLI.',
|
||||
);
|
||||
setTimeout(() => {
|
||||
process.exit(1);
|
||||
setTimeout(async () => {
|
||||
await runExitCleanup();
|
||||
process.exit(ExitCodes.FATAL_CONFIG_ERROR);
|
||||
}, 100);
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user