-
Notifications
You must be signed in to change notification settings - Fork 21
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
Reset terminal attributes after exit #20
Comments
Not sure if there's a particular key binding to exit "properly" but EDIT: Default is |
Hm, strange that Ctrl+C stopped working. If you want to play around with it, the intercept code is here: https://github.com/chase/awrit/blob/main/awrit/input_event_handler.cc#L23-L30 Realistically, awrit should have a signal handler to handle any terminating event and exit cleanly. I'm rather busy for a while so I can't put time into this right now, but if you figure out a fix for this I'll gladly accept a PR |
According to
While Infact, it seems to be caught and handled the same as |
Sorry, that was an error on my part. Corrected it.
Oh, I see... thanks. |
I just made a fresh build and I can't reproduce this issue in Kitty. It correctly resets the terminal attributes. I believe this might be a wezterm-specific issue. While wezterm should mostly work, there are bound to be issues like this that arise since I primarily use and test things in Kitty. Detecting if things are running in wezterm and apply additional fixes is probably the best we can do in this case. |
I also was having problems with ctrl+c -- turns out, doing ctrl+c + c (ctrl+c followed by another c while holding ctrl) works. I don't know why that's happening. |
in ghostty, if i use ctrl-c to kill the awrit, the terminal cursor will dispeared. i think these maybe the same problem. |
I'm not able to exit awrit using ctrl+c, nor ctrl+c+c. I have to close the window/pane and recreate it. Using kitty 0.36.4. Other than that, this is super cool for my environment!! |
@rockorager / @rustbuckett I tested out #50 and it works great with Ghostty. Seemingly doesn't fix Kitty though YMMV. |
Issue:
After exiting awrit (using
pkill awrit
bc ctrl+c doesn't work for me 😞), moving the mouse results in escape codes being written to the terminal. This is fixed by atput reset
.Expected behavior:
awrit
sets the terminal attributes to their previous values, or if impossible, then resets them to default (essentiallytput reset
)Environment:
wezterm 20230712-072601-f4abf8fd on Ubuntu 22.04.2 LTS
The text was updated successfully, but these errors were encountered: