Shortcut to directly select the hint commands #20036

Closed
opened 2026-01-31 07:01:27 +00:00 by claunia · 3 comments
Owner

Originally created by @xenkuo on GitHub (Jun 6, 2023).

Description of the new feature/enhancement

The terminal could automatically show the possible command when you typing it, but seems there's no shortcut could directly select it. I have tried to google or bing(😄 )it a lot, still no any clues.

The hint command is just below commands in red rectangle:
image

Proposed technical implementation details (optional)

I want to confirm is there such a shortcut to select it? If yes, please tell me, thank you in advance; if no, any plan for it?

Originally created by @xenkuo on GitHub (Jun 6, 2023). <!-- 🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨 I ACKNOWLEDGE THE FOLLOWING BEFORE PROCEEDING: 1. If I delete this entire template and go my own path, the core team may close my issue without further explanation or engagement. 2. If I list multiple bugs/concerns in this one issue, the core team may close my issue without further explanation or engagement. 3. If I write an issue that has many duplicates, the core team may close my issue without further explanation or engagement (and without necessarily spending time to find the exact duplicate ID number). 4. If I leave the title incomplete when filing the issue, the core team may close my issue without further explanation or engagement. 5. If I file something completely blank in the body, the core team may close my issue without further explanation or engagement. All good? Then proceed! --> # Description of the new feature/enhancement The terminal could automatically show the possible command when you typing it, but seems there's no shortcut could directly select it. I have tried to google or bing(😄 )it a lot, still no any clues. The hint command is just below commands in red rectangle: ![image](https://github.com/microsoft/terminal/assets/59609423/f8e90ace-3840-4ea2-a3d1-f63bd34ca562) <!-- A clear and concise description of what the problem is that the new feature would solve. Describe why and how a user would use this new functionality (if applicable). --> # Proposed technical implementation details (optional) <!-- A clear and concise description of what you want to happen. --> I want to confirm is there such a shortcut to select it? If yes, please tell me, thank you in advance; if no, any plan for it?
Author
Owner

@zadjii-msft commented on GitHub (Jun 6, 2023):

  1. This is technically a PsReadline feature, not a Terminal one. For more reading, see: Using predictors in PSReadLine
  2. Press the right arrow key to fill in the suggestion
@zadjii-msft commented on GitHub (Jun 6, 2023): 1. This is technically a PsReadline feature, not a Terminal one. For more reading, see: [Using predictors in PSReadLine](https://learn.microsoft.com/en-us/powershell/scripting/learn/shell/using-predictors?view=powershell-7.3) 2. Press the right arrow key to fill in the suggestion
Author
Owner

@xenkuo commented on GitHub (Jun 11, 2023):

@zadjii-msft , thanks for the response, at least there's a key to directly select it now.

@xenkuo commented on GitHub (Jun 11, 2023): @zadjii-msft , thanks for the response, at least there's a key to directly select it now.
Author
Owner

@xenkuo commented on GitHub (Jun 17, 2023):

For anyone want to remap the key bind to shift+tab, paste below line to $PROFILE
Set-PSReadLineKeyHandler -Chord "Shift+Tab" -Function AcceptSuggestion

@xenkuo commented on GitHub (Jun 17, 2023): For anyone want to remap the key bind to shift+tab, paste below line to $PROFILE `Set-PSReadLineKeyHandler -Chord "Shift+Tab" -Function AcceptSuggestion`
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#20036