Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/nightroman/PS-GuiCompletion
A graphical menu for PowerShell tab completions.
https://github.com/nightroman/PS-GuiCompletion
Last synced: 4 days ago
JSON representation
A graphical menu for PowerShell tab completions.
- Host: GitHub
- URL: https://github.com/nightroman/PS-GuiCompletion
- Owner: nightroman
- License: mit
- Created: 2021-03-15T03:05:37.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2023-12-22T13:58:08.000Z (11 months ago)
- Last Synced: 2024-10-30T12:13:25.452Z (11 days ago)
- Language: PowerShell
- Homepage:
- Size: 198 KB
- Stars: 46
- Watchers: 2
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- jimsghstars - nightroman/PS-GuiCompletion - A graphical menu for PowerShell tab completions. (PowerShell)
README
# GuiCompletion for PowerShell
GUI-style tab-completion menu for PowerShell. It integrates with PSReadLine
which comes installed in PowerShell, and the GUI code is lifted from PowerTab.This repository clones and continues the original [PS-GuiCompletion](https://github.com/cspotcode/PS-GuiCompletion)
created by [@cspotcode](https://github.com/cspotcode).
The same module [GuiCompletion](https://www.powershellgallery.com/packages/GuiCompletion)
is developed here starting from v0.9.0.**Screenshots**
[q1]: docs/q1.png "Command completion"
[q2]: docs/q2.png "Parameter completion"
[q3]: docs/q3.png "Path completion"| ![command][q1] | ![parameter][q2] | ![path][q3] |
|-|-|-|## Installation
Install from the PowerShell Gallery ([GuiCompletion Gallery page](https://www.powershellgallery.com/packages/GuiCompletion)):
Install-Module -Name GuiCompletion -Scope CurrentUser
Omit `-Scope` to install for all users if you have administrator permissions.
## Usage
Use with the default Ctrl+Spacebar key shortcut:
Install-GuiCompletion
or with another key shortcut:
Install-GuiCompletion -Key Tab
`Install-GuiCompletion` wraps PSReadLine's [Set-PSReadLineKeyHandler](https://github.com/lzybkr/PSReadLine#usage).
For more advanced scenarios, you can call the relevant PSReadLine commands directly:Set-PSReadlineKeyHandler -Key Alt+Spacebar -ScriptBlock { Invoke-GuiCompletion }
Add these configuration commands to your PowerShell profile.
Otherwise your configuration will not be applied to new PowerShell sessions.## Options
The exported variable `$GuiCompletionConfig` provides the following default
console colors and options. They may be changed in a profile or interactively.```
Colors : @{TextColor=DarkMagenta;
BackColor=White;
SelectedTextColor=White;
SelectedBackColor=DarkMagenta;
BorderTextColor=DarkMagenta;
BorderBackColor=White;
BorderColor=DarkMagenta;
FilterColor=DarkMagenta}
DoubleBorder : True
MinimumTextWidth : 25
FastScrollItemCount : 10
AutoReturnSingle : True
ScrollDisplayDown : True
DotComplete : True
AutoExpandOnDot : True
BackSlashComplete : True
AutoExpandOnBackSlash : True
CustomComplete : True
CustomCompletionChars : ()[]:
````ScrollDisplayDown` tells to scroll the display if necessary in order to show
the list below the caret. This works around redrawing issues after the list
shown above the caret in some terminals.## See also
- [GuiCompletion Release Notes](https://github.com/nightroman/PS-GuiCompletion/blob/main/Release-Notes.md)