gemini-cli icon indicating copy to clipboard operation
gemini-cli copied to clipboard

Feature Request: Add shortcut to clear all input content in the message box

Open noejunior299 opened this issue 1 year ago • 12 comments

What would you like to be added?

While using Gemini CLI, in the message input box where we paste or write prompts, it would be very helpful to have a keyboard shortcut to quickly select and delete all the input content.

Currently, when we paste a long context and want to clear it entirely, we have to hold down the Backspace or Delete key, which is inefficient and frustrating.

Suggested Solution:

Implement a shortcut like Ctrl+U, Ctrl+L, or Ctrl+A followed by Delete/Backspace to clear the input box instantly.

Alternatively, allow a simple command like :clear to quickly reset the input field.

Why is this needed?

Benefits:

Greatly improves usability, especially for users working with large prompts.

Increases productivity and reduces frustration during regular use.

Additional context

No response

noejunior299 avatar Jul 19 '25 14:07 noejunior299

up

DomizianoAtticciati avatar Jul 20 '25 11:07 DomizianoAtticciati

up

noejunior299 avatar Jul 20 '25 13:07 noejunior299

Closing this issue as it only contains 'up' comments and lacks context.

srithreepo avatar Jul 21 '25 05:07 srithreepo

I'm waiting for a response to my issue, whether it will be answered, whether they are already implementing it, whether they are thinking of implementing it, etc.

noejunior299 avatar Jul 22 '25 11:07 noejunior299

@srithreepo don't close this off, it's a real issue.

It's pretty simple too - you write a bunch of stuff in the input field, and then decide you don't want to actually send it.

How do you clear it other than pressing backspace a million times?

Claude Code has Ctrl-C shortcut, which cancels the current command, including clearing whatever text you had started writing. Pressing it multiple times in a row exits (like Gemini)

You should just implement the same shortcut IMO.

asgeo1 avatar Jul 24 '25 00:07 asgeo1

Found possible duplicate issues:

  • #4971: (#0.9011334180831909)

gsquared94 avatar Jul 30 '25 00:07 gsquared94

Hi @noejunior792. I believe using Ctrl+C will clear the input area. Closing this, but please feel free to reopen if you're still having trouble.

galdawave avatar Aug 22 '25 18:08 galdawave

@galz10 thanks, thanks, you resolve my problem.

noejunior299 avatar Aug 28 '25 13:08 noejunior299

I get press Ctrl + C again to exit. So doesn't seem to solve the problem.

samos123 avatar Sep 30 '25 05:09 samos123

But Ctrl+C also stops the agent from working, what if I want to not interrupt it, and clear the input?

bohemian-miser avatar Dec 18 '25 23:12 bohemian-miser

Please re-open as this isn't a proper solution

jonah-propcode avatar Jan 28 '26 03:01 jonah-propcode

When I press ctrl+c I get the following msg: "Press Ctrl+C again to exit." and the text box would not clean as would I expect in a terminal prompt.

 Press Ctrl+C again to exit.
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
 > asdfasf
   asdfasdfasdf
   asdfasafd
   fdsdsg
▄▄▄▄▄▄▄▄▄▄▄▄▄▄

Imo the issue should be re-opened also.

n-eko-ai avatar Mar 20 '26 21:03 n-eko-ai