summaryrefslogtreecommitdiff
path: root/docs/cli/commands.md
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 /docs/cli/commands.md
parent52980510c92deb4af4c9012ae23bd67f169c1a32 (diff)
feat: add GEMINI_CLI environment variable to spawned shell commands (#4791)
Diffstat (limited to 'docs/cli/commands.md')
-rw-r--r--docs/cli/commands.md2
1 files changed, 2 insertions, 0 deletions
diff --git a/docs/cli/commands.md b/docs/cli/commands.md
index e1692ccd..f6e9451e 100644
--- a/docs/cli/commands.md
+++ b/docs/cli/commands.md
@@ -282,3 +282,5 @@ The `!` prefix lets you interact with your system's shell directly from within G
- When exited, the UI reverts to its standard appearance and normal Gemini CLI behavior resumes.
- **Caution for all `!` usage:** Commands you execute in shell mode have the same permissions and impact as if you ran them directly in your terminal.
+
+- **Environment Variable:** When a command is executed via `!` or in shell mode, the `GEMINI_CLI=1` environment variable is set in the subprocess's environment. This allows scripts or tools to detect if they are being run from within the Gemini CLI.