Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question: Can this be used outside of PowerShell? #1045

Open
avestura opened this issue Sep 13, 2019 · 1 comment
Open

Question: Can this be used outside of PowerShell? #1045

avestura opened this issue Sep 13, 2019 · 1 comment
Labels
Issue-Enhancement It's a feature request. Not-Planned
Milestone

Comments

@avestura
Copy link

avestura commented Sep 13, 2019

Hello

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

Is using this lib for such a task (building a customized REPL for another .NET Language other than PowerShell) feasible or not?

Thank you.

@lzybkr
Copy link
Member

lzybkr commented Sep 13, 2019

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Issue-Enhancement It's a feature request. Not-Planned
Projects
None yet
Development

No branches or pull requests

3 participants