summaryrefslogtreecommitdiff
path: root/packages/cli/src/ui/hooks/shellCommandProcessor.ts
diff options
context:
space:
mode:
authorDaniel Lee <[email protected]>2025-07-24 10:13:00 -0700
committerGitHub <[email protected]>2025-07-24 17:13:00 +0000
commit3dd6e431df057af47b96990d0c9c6477ccfbe452 (patch)
tree8a75c928b0c558d82a5470a504ff57f48002f801 /packages/cli/src/ui/hooks/shellCommandProcessor.ts
parent52980510c92deb4af4c9012ae23bd67f169c1a32 (diff)
feat: add GEMINI_CLI environment variable to spawned shell commands (#4791)
Diffstat (limited to 'packages/cli/src/ui/hooks/shellCommandProcessor.ts')
-rw-r--r--packages/cli/src/ui/hooks/shellCommandProcessor.ts4
1 files changed, 4 insertions, 0 deletions
diff --git a/packages/cli/src/ui/hooks/shellCommandProcessor.ts b/packages/cli/src/ui/hooks/shellCommandProcessor.ts
index 5d2b3166..9e343f90 100644
--- a/packages/cli/src/ui/hooks/shellCommandProcessor.ts
+++ b/packages/cli/src/ui/hooks/shellCommandProcessor.ts
@@ -72,6 +72,10 @@ function executeShellCommand(
cwd,
stdio: ['ignore', 'pipe', 'pipe'],
detached: !isWindows, // Use process groups on non-Windows for robust killing
+ env: {
+ ...process.env,
+ GEMINI_CLI: '1',
+ },
});
// Use decoders to handle multi-byte characters safely (for streaming output).