codex icon indicating copy to clipboard operation
codex copied to clipboard

Implement CTRL + L or similar commands to discard a prompt

Open thetinygoat opened this issue 3 months ago • 3 comments

What feature would you like to see?

Currently if i have typed a long prompt and i want to cancel it, either i have to delete it manually or quit the process and start again. if i have had a long conversation closing the process leads to losing context.

Are you interested in implementing this feature?

No response

Additional information

No response

thetinygoat avatar Sep 03 '25 19:09 thetinygoat

I agree, Ctrl-C and/or Esc should clear the current prompt (and Ctrl-C should not exit, even with confirmation). For now, Ctrl-U will delete an entire line. Since a prompt is probably not that many lines, holding down Ctrl-U is not a terrible solution.

rben01 avatar Sep 03 '25 21:09 rben01

@rben01 I have implement esc to clear the user input You can try using my version of codex https://github.com/thammachet/hopefully-better-codex Run the following command cd codex-rs cargo install --path cli --profile dev --target-dir ./target

Waitting for approval and I am creating pr

thammachet avatar Sep 04 '25 19:09 thammachet

I agree, Ctrl-C and/or Esc should clear the current prompt (and Ctrl-C should not exit, even with confirmation). For now, Ctrl-U will delete an entire line. Since a prompt is probably not that many lines, holding down Ctrl-U is not a terrible solution.

thank you

chrisbarless avatar Sep 06 '25 16:09 chrisbarless