Coder Social home page Coder Social logo

ps-guicompletion's Introduction

GuiCompletion for PowerShell

This enables a GUI-style tab-completion menu for PowerShell. It integrates with PSReadLine which comes installed in PowerShell by default, and the GUI code is lifted straight from PowerTab.

Bugs? Please open an issue on Github: https://github.com/cspotcode/PS-GuiCompletion/issues

Animated example

Installation

Install from the PowerShell Gallery. (GuiCompletion's Gallery page)

Install-Module -Name GuiCompletion -Scope CurrentUser

You can omit -Scope but I use it to avoid requiring Administrator permissions.

Usage

Register it with the default Ctrl+Spacebar key shortcut:

Install-GuiCompletion

...or with another key shortcut:

Install-GuiCompletion -Key Tab

Install-GuiCompletion is a one-line helper that wrap PSReadLine's Set-PSReadLineKeyHandler cmdlet. For more advanced scenarios, you can call the relevant PSReadLine commands directly:

Set-PSReadlineKeyHandler -Key Alt+Spacebar -ScriptBlock { Invoke-GuiCompletion }

You'll want to add these configuration commands to your PowerShell profile. Otherwise your configuration will not be applied to new PowerShell sessions.

TODOs

Mac and Linux support. GetKeyState and some of the rendering code is apparently Windows-only.

Changelog

v0.8.1

  • Fixes broken publication of v0.8.0

v0.8.0

  • Switches to Windows' default menu color scheme (#5, @nightroman)
    • If you want to use the old theme or customize colors, modify the $GuiCompletionConfig.Colors global variable.
  • Fixes rendering glitch where some vertical lines could be left over after the menu closes (#6, @nightroman)
  • Switches to TabExpansion2 for computing completions, which allows other modules to plugin custom completions (#7, @nightroman)

ps-guicompletion's People

Contributors

cspotcode avatar nightroman avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.