mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-02-01 22:48:03 +00:00
Introduce GEMINI_CLI_HOME for strict test isolation (#15907)
This commit is contained in:
@@ -33,10 +33,12 @@ const argv = yargs(hideBin(process.argv)).option('q', {
|
||||
default: false,
|
||||
}).argv;
|
||||
|
||||
const homedir = () => process.env['GEMINI_CLI_HOME'] || os.homedir();
|
||||
|
||||
let geminiSandbox = process.env.GEMINI_SANDBOX;
|
||||
|
||||
if (!geminiSandbox) {
|
||||
const userSettingsFile = join(os.homedir(), GEMINI_DIR, 'settings.json');
|
||||
const userSettingsFile = join(homedir(), GEMINI_DIR, 'settings.json');
|
||||
if (existsSync(userSettingsFile)) {
|
||||
const settings = JSON.parse(
|
||||
stripJsonComments(readFileSync(userSettingsFile, 'utf-8')),
|
||||
|
||||
Reference in New Issue
Block a user