Windows Terminal 智能提示

发布时间 2023-06-16 14:56:22作者: 流星Studio

安装PSReadLine

Install-Module -Name PSReadLine -AllowClobber -Force

打开$profile

notepad $profile

配置补全

在$profile中配置

# Shows navigable menu of all options when hitting Tab
Set-PSReadlineKeyHandler -Key Tab -Function MenuComplete

# Autocompletion for arrow keys
Set-PSReadlineKeyHandler -Key UpArrow -Function HistorySearchBackward
Set-PSReadlineKeyHandler -Key DownArrow -Function HistorySearchForward

# auto suggestions
Import-Module PSReadLine
Set-PSReadLineOption -PredictionSource History