An open API service indexing awesome lists of open source software.

https://github.com/andria-dev/pwsh-readlinewithhistory

A module for reading from the console with up and down arrow history. Includes support for basic backspace, delete, left arrow, right arrow, home, and end keys.
https://github.com/andria-dev/pwsh-readlinewithhistory

Last synced: 2 months ago
JSON representation

A module for reading from the console with up and down arrow history. Includes support for basic backspace, delete, left arrow, right arrow, home, and end keys.

Awesome Lists containing this project

README

          

# pwsh-ReadLineWithHistory

Works on Linux.

## Usage

```pwsh
Import-Module ReadLineWithHistory;
$Reader = New-ReadLineWithHistory;

while ($True) {
$Command = $Reader.ReadLine("$env:USER - $env:PWD> ");
# Process the command
}

# Or

$Input = $Reader.ReadLine("PROMPT: ");
# Process the input
$Input = $Reader.ReadLine("PROMPT: ");
# Process the input
```