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

new tty proposal #64

Open
progrium opened this issue Jan 17, 2024 · 3 comments
Open

new tty proposal #64

progrium opened this issue Jan 17, 2024 · 3 comments

Comments

@progrium
Copy link
Contributor

progrium commented Jan 17, 2024

We currently implement an oversimplified recreation of Linux PTYs, where you can make a "terminal" that starts a process and then STDIO is streamed altogether to be wired up directly to a terminal emulator. It's most obviously lacking the ability to resize a terminal, but we also don't implement much of the "line discipline" of PTYs. The latter is less important because specific line disciplines aren't used much any more other than switching into "raw" mode. But not being able to size/resize terminals causes terminal UIs to glitch and it gets in the way of using certain programs.

Unfortunately, terminal resize changes are communicated to processes via signals, which we don't have (tracked by #78). The current plan is to implement our own GOOS runtime that implements our own os/signal so we can at least signal programs compiled with our compiler with GOOS=wanix. This should give us other benefits as well, but seems like a reasonable solution to terminal resizing. Our tty system will have to be updated to support this.

We will still not have real Linux PTYs, but I'm not in dire need of them. In fact, I'd rather model our tty system after the Plan 9 console system, which is similar but different. Simpler if I recall.

Since we have #78, this issue will track implementing a full PTY/console system based on Plan 9.

@taramk
Copy link
Collaborator

taramk commented Feb 14, 2024

blocks #69

@taramk
Copy link
Collaborator

taramk commented Mar 20, 2024

there are issues with the terminal that cause micro to not be able to rerender lines as you're working, and in the shell the last character that you've typed sometimes get occluded by the cursor (check if this is rare or not)

@progrium
Copy link
Contributor Author

progrium commented Apr 1, 2024

I've updated the description of this issue to explain the problem and a plan to emulate Plan 9. It's now de-prioritized.

@progrium progrium removed this from the 0.2 milestone Apr 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants