Psreadline: Question: Can this be used outside of PowerShell?

Created on 13 Sep 2019  路  1Comment  路  Source: PowerShell/PSReadLine

Hello

I wanted to know if I can use PSReadLine as a .NET library for creating a customized REPL for F#.NET.
This module already has tones of useful features like Syntax highlighting, auto-complete, etc which reimplementing them using basic .NET Console class seems to reinvent the wheel.

I would be happy if you let me know if using this lib for such task (building a customized REPL for another .NET Language other than PowerShell) is feasible or not.

Thank you.

Issue-Enhancement Not-Planned

Most helpful comment

It would take some refactoring to make PSReadLine usable outside of PowerShell. I do think that would be useful though - I've considered doing this for fsi.

I like the approach taken in rustyline, based on Linenoise. For example, syntax coloring, completion, and hints (a feature missing in PSReadLine) are implemented as traits (an interface in the .Net world).

It might be worth wrapping one of these libraries in .Net. I actually considered doing a proof of concept with rustyline to see how well hinting might work.

>All comments

It would take some refactoring to make PSReadLine usable outside of PowerShell. I do think that would be useful though - I've considered doing this for fsi.

I like the approach taken in rustyline, based on Linenoise. For example, syntax coloring, completion, and hints (a feature missing in PSReadLine) are implemented as traits (an interface in the .Net world).

It might be worth wrapping one of these libraries in .Net. I actually considered doing a proof of concept with rustyline to see how well hinting might work.

Was this page helpful?
0 / 5 - 0 ratings