Stebalien / term

A Rust library for terminfo parsing and terminal colors.
https://stebalien.github.io/doc/term/term/
Apache License 2.0
178 stars 49 forks source link

terminfo: Pretend to be xterm if Windows console supports ansi #87

Closed MoSal closed 6 years ago

MoSal commented 6 years ago

Windows people seem to be fine with this: Microsoft/WSL#1446

I still think a precise terminfo file with the list of supported sequences documented in the below link would be ideal: https://docs.microsoft.com/en-us/windows/console/console-virtual-terminal-sequences

But I didn't find such a file. And I don't know how to generate one easily.

A copy of xterm-256color terminfo file is included at compile-time. I copied it from ncurses 6.1.

With this commit, term should be on par with ansi_term for Windows 10 users.


This branch includes the commit from #86.

MoSal commented 6 years ago

Fixed AppVeyor build. I didn't see the error because I was testing with a dependency list that includes isatty which depends on winapi with "consoleapi" enabled.

Travis builds are failing because from_bytes() is only used on Windows.

Edit: Travis build should be fixed now.

Stebalien commented 6 years ago

I've merged your other PR. Mind rebasing?

MoSal commented 6 years ago

Accidentally deleted the branch while testing.

Edited and rebased in #88