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

Feature Request: Add ability to detect when running in terminal #2470

Closed
avylove opened this issue Aug 18, 2019 · 1 comment
Closed

Feature Request: Add ability to detect when running in terminal #2470

avylove opened this issue Aug 18, 2019 · 1 comment
Labels
Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing.

Comments

@avylove
Copy link

avylove commented Aug 18, 2019

Description of the new feature/enhancement

There doesn't seem to be an obvious way to detect when running from the terminal. This is a issue for applications and libraries where behavior is dependent on the terminal. For example, a Python library may require colorama for some terminals and not others.

Proposed technical implementation details

The most common and portable way to do this is to set the TERM environment variable when initializing the terminal.

@avylove avylove added the Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. label Aug 18, 2019
@ghost ghost added Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting Needs-Tag-Fix Doesn't match tag requirements labels Aug 18, 2019
@DHowett-MSFT
Copy link
Contributor

Duplicate: #1040, but honestly, Windows Terminal is built with the same support for VT sequences as conhost, which attempts to be as close to xterm-256color as we can get it. Practically, that means that Python library should just use colorama, because it'll work properly on most recent versions of Windows 10 with and without Terminal installed.

@DHowett-MSFT DHowett-MSFT added the Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing. label Aug 18, 2019
@ghost ghost removed the Needs-Tag-Fix Doesn't match tag requirements label Aug 18, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing.
Projects
None yet
Development

No branches or pull requests

2 participants