pty icon indicating copy to clipboard operation
pty copied to clipboard

Add Windows ConPTY support

Open TerryHowe opened this issue 2 months ago • 3 comments

This adds full Windows support using ConPTY (Windows Pseudo Console API). Key changes include:

  • New Pty and Tty interfaces to abstract Unix *os.File and Windows handles
  • Windows-specific implementation using ConPTY API
  • Updated API to return interfaces instead of concrete *os.File types
  • Cross-platform window size management
  • Process lifecycle management for Windows

I have rebased and squashed the commits to one commit and listed the other authors as co-authors. This will make future rebases easier.

Closes: https://github.com/creack/pty/issues/161 Closes: https://github.com/creack/pty/issues/95 Closes: https://github.com/creack/pty/pull/155

TerryHowe avatar Sep 30 '25 14:09 TerryHowe

Have you had a chance to find the mistake I had in the code where we're getting an invalid handler when we're trying to set the size because I haven't had the time to actually look into the issue fully? I think it's just a simple mistake I have somewhere.

photostorm avatar Sep 30 '25 14:09 photostorm

Converted to draft for now, I need to fix somethings according to my testing.

TerryHowe avatar Sep 30 '25 19:09 TerryHowe

Nice!! Thank you for taking the time to work on this

adrivn avatar Oct 21 '25 11:10 adrivn