summaryrefslogtreecommitdiff
path: root/packages/cli/src/ui/hooks/shellCommandProcessor.ts
AgeCommit message (Collapse)Author
2025-08-24Refactor: Update hardcoded "gemini" command to "regex"Castor Gemini
2025-08-22feat(cli): process shell output with geminiCastor Gemini
This change extends the shell command processing functionality. After a shell commands output is successfully written to a log file in /tmp, the application will now automatically invoke `gemini --input` with the generated filename to process the contents of that log file. This enables a seamless workflow where shell command results can be immediately used as context for further interactions with the Gemini CLI.
2025-08-22feat(cli): log shell command output to a fileCastor Gemini
This change modifies the `shellCommandProcessor` to write the complete output of any executed shell command to a log file in the /tmp directory. The filename is formatted as `gemini-cli-output-<timestamp>.log`. This provides a persistent record of shell command interactions for debugging and auditing purposes, without altering the user-facing display in the CLI.
2025-08-19feat(core): refactor shell execution to use node-pty (#6491)Gal Zahavi
Co-authored-by: Jacob Richman <[email protected]>
2025-08-15Revert #6088 (#6328)Gal Zahavi
2025-08-14feat(core): refactor shell execution to use node-pty (#6088)Gal Zahavi
2025-07-26refactor(core): Centralize shell logic into ShellExecutionService (#4823)Abhi
2025-07-24feat: add GEMINI_CLI environment variable to spawned shell commands (#4791)Daniel Lee
2025-07-21fix: character encoding issues in shell command processor (#1949)BOYI
Co-authored-by: Jacob Richman <[email protected]> Co-authored-by: Sandy Tao <[email protected]>
2025-07-21Various spelling improvements (#3497)Josh Soref
Signed-off-by: Josh Soref <[email protected]> Co-authored-by: Sandy Tao <[email protected]>
2025-07-19Make shell output consistent. (#4469)Jacob Richman
2025-06-25fix: prepublish changes to package names (#1420)Brandon Keiji
2025-06-15feat: Adds shell command context to gemini history (#1076)Abhi
2025-06-09Windows: Refactor Shell Scripts to Node.js for Cross-Platform Compatibility ↵matt korwel
(#784)
2025-06-07refactor: rename gemini-code to gemini-cli (#822)cperry-goog
2025-06-02strip ansi from shell output (#699)Olcan
2025-05-30Rename server->core (#638)Tommaso Sciortino
2025-05-30tweaks to shell abort logic based on feedback (#618)Olcan
2025-05-30allow aborting of shell mode (!) commands, similar to shell tool commands. ↵Olcan
fix bug that prevented aborts after first abort. more robust killing logic (#616)
2025-05-30update shell output at an interval to reduce flicker (#614)Olcan
2025-05-28much improved support for background processes, avoiding termination (via ↵Olcan
SIGPIPE) or eventual blocking (e.g. due to filled OS buffers) (#586)
2025-05-21use pending history item for shell mode, update as output is received (#471)Olcan
2025-05-21space outputs in shell mode (#469)Olcan
2025-05-21switch to spawn for shell mode (#467)Olcan
2025-05-21fix exit code for shell mode also (#466)Olcan
2025-05-20fix(cli): Prevent truncation of first character in shell commandsTaylor Mullen
- The shell command processor was incorrectly truncating the first character of the command (e.g., 'ls' became 's') due to an erroneous `slice(1)` operation, likely introduced during a previous merge. This change removes the slice, ensuring the full command is processed. - Introduces unit tests for the shellCommandProcessor hook. - Fixes a minor grammatical issue in the display of GEMINI.md file count.
2025-05-19fix: Ensure user written `!` is treated opaquely if not in shell mode\n\n- ↵Taylor Mullen
Addresses an issue where commands prefixed with `!` (e.g., `!ls`) were incorrectly handled by the shell command processor if the `!` was added after initially typing the command.\n- Ensures that such commands are correctly forwarded to the Gemini model.\n- Updates `useGeminiStream` to be aware of shell mode to properly manage streaming state.\n\nFixes https://buganizer.corp.google.com/issues/418761305
2025-05-19switch from console.warn to info item (#440)Olcan
2025-05-19warn on cd in shell mode. done robustly based on lessons from shell tool. ↵Olcan
logs to console.warn for now, and does not restore (but see comment on how to restore) (#438)
2025-05-18feat(cli): Introduce toggleable shell mode with enhanced UITaylor Mullen
- Implements a toggleable shell mode, removing the need to prefix every command with `!`. - Users can now enter and exit shell mode by typing `!` as the first character in an empty input prompt. - The input prompt visually indicates active shell mode with a distinct color and `! ` prefix. - Shell command history items (`user_shell`) are now visually differentiated from regular user messages. - This provides a cleaner and more streamlined user experience for frequent shell interactions. Fixes https://b.corp.google.com/issues/418509745
2025-05-16refactor: derive streaming state from tool calls and isresponding state (#376)Brandon Keiji
2025-05-13refactor: move nested debugmessage and slashcommand hooks outside of ↵Brandon Keiji
useGeminiStream (#341)
2025-05-06refactor(cli): Centralize history management via useHistoryManager hook (#261)Allen Hutchison
2025-05-01prevent crash on empty shell cmd with $ or ! (#240)Olcan
2025-04-30Added bang(!) commands as a shell passthroughSeth Troisi