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

nodejs istTTY is true on git-bash but undefined on msys2 #3051

Closed
wszgrcy opened this issue Jun 22, 2022 · 4 comments
Closed

nodejs istTTY is true on git-bash but undefined on msys2 #3051

wszgrcy opened this issue Jun 22, 2022 · 4 comments
Labels
not-bug General questions, not an issue

Comments

@wszgrcy
Copy link

wszgrcy commented Jun 22, 2022

Describe the issue

when run node -p -e "process.stdout.isTTY" on git-bash(git for window,mingw64,mintty 3.6.1) return true.
on msys2(or mingw64 mingw32....),return undefined
image
image

  • same node version (node 16.14.2),same mintty version(3.6.1),but msys2 display does not meet expectations...
  • on vscode terminal use msys2 bash also return true
  • I try to copy msys2.exe in git folder and run, same return true
  • I find mintty Improve support for native console programs mintty/mintty#56 has resolve on 3.1.0,is the same problem?

Steps to Reproduce the Problem

  1. open E:\msys2\msys2.exe
  2. run node -p -e "process.stdout.isTTY"

node is download on https://nodejs.org/

  1. return undefind
  2. What did you expect to happen instead?

retrun true

Additional Context: Operating System, Screenshots

If applicable, add screenshots to help explain your problem.

  • OS: [e.g. Windows 10 19044.1165 ]
  • '...'
@Biswa96
Copy link
Member

Biswa96 commented Jun 22, 2022

The ConPTY feature in not enabled by default in msys2 environments. It has to be manually enabled using MSYS=enable_pcon environment variable before initiating any msys2 instance.

@Biswa96 Biswa96 added the not-bug General questions, not an issue label Jun 22, 2022
@lazka
Copy link
Member

lazka commented Jun 22, 2022

It's probably time we start thinking about enabling it by default..

@Biswa96
Copy link
Member

Biswa96 commented Jun 23, 2022

I have seen some msys2/cygwin tools have weird behavior with conpty e.g. autotools, tmux etc.

@wszgrcy
Copy link
Author

wszgrcy commented Jun 23, 2022

@Biswa96 thanks

@wszgrcy wszgrcy closed this as completed Jun 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
not-bug General questions, not an issue
Projects
None yet
Development

No branches or pull requests

3 participants