fix(registry): vim isatty via host_tty, sigprocmask decl, termios force-include#262
Merged
Conversation
|
🚅 Environment secure-exec-pr-262 in rivet-frontend has no services deployed. 🚅 Deployed to the secure-exec-pr-262 environment in secure-exec
|
- isatty delegates to host_tty (PTY fd wrongly reported not-a-tty by wasi-libc) - implement real termcap tgoto() so parameterized caps (cursor motion, scroll region) are emitted under HAVE_TGETENT instead of silently dropped - declare sigprocmask + force-include termios so a clean configure build links
0b3e3c3 to
79d1af3
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Three fixes to the source-built vim's terminal handling:
isattytohost_tty.isatty. wasi-libc's fdstat-based isatty rejects a PTY fd that carries seek/tell rights, so vim printed "Output is not to a terminal" and refused full-screen mode. Now vim enters full-screen and edits/writes files byte-exact over the shell PTY (validated via thejust shellgrandchild path).<signal.h>and declaresigprocmaskin compat.h. A clean-checkout configure definesHAVE_SIGPROCMASK(posix_stubs.c implements it), but wasisignal.hdeclares no prototype, so os_unix.c failed with implicit-declaration on a fresh build. The prior build only linked by build-state luck.<termios.h>in compat.h soTIOCGWINSZ/struct winsizeare defined in every TU (os_unix.c's window-size query is#ifdef TIOCGWINSZ-gated).Known limitation: under
@xterm/headlessthe status line renders ~2 rows high (vim relies on default bottom-margin scroll behavior rather than emitting an explicit scroll region like the older hand-built binary did). File editing is byte-exact; needs verification in a real terminal.