4461 Commits

Author SHA1 Message Date
Mitchell Hashimoto
5e0e0b2bd4 macos: wait for window to become visible to set blur
Fixes #1181
2023-12-29 21:58:30 -08:00
Mitchell Hashimoto
85c386f45d termio: remove old warning log statement used for debugging 2023-12-29 21:25:07 -08:00
Mitchell Hashimoto
a159eafc18 Merge pull request #1180 from mitchellh/change-macos-launch
Modify the way the login shell is launched on macOS to reduce nesting
2023-12-29 15:50:18 -08:00
Mitchell Hashimoto
a69ec2127e termio/exec: use bash instead of zsh for shell launching 2023-12-29 15:41:11 -08:00
Mitchell Hashimoto
1652b9049a Merge pull request #1188 from rockorager/website-script-fix
website: fix ich and il scripts
2023-12-29 13:59:53 -08:00
Tim Culverhouse
165bbf4e56 website(il): fix test script
The IL V-3 test script has the cursor in the wrong position. Confirmed
with xterm. The cursor should end up in the first column.
2023-12-29 15:57:41 -06:00
Tim Culverhouse
b7ad30b067 website(ich): fix test script v1
The V-1 Test script was missing a printf statement. Add the missing
statement to make the expected output correct.

Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
2023-12-29 15:57:41 -06:00
Mitchell Hashimoto
8feab70fa2 Merge pull request #1187 from rockorager/el-script-fix
website(el): clarify cursor position in test script
2023-12-29 13:23:36 -08:00
Tim Culverhouse
27be196fb4 website(el): clarify cursor position in test script
The test script for `el` shows the cursor being on the right side of
`X`, however in xterm and ghostty the cursor is _on_ the `X`. Delete the
cursor position and add a comment on where the cursor should be.
2023-12-29 15:19:20 -06:00
Mitchell Hashimoto
6763e9ef37 Merge pull request #1186 from rockorager/website-cub-fix
website: fix `cub` test script
2023-12-29 12:54:07 -08:00
Tim Culverhouse
23cd1d95e9 website: fix cub test script
The `CUB` V2 test script has a trailing echo which pushes the cursor
down one line, making the expected output incorrect. Remove the `echo`
command so the cursor position is as shown.
2023-12-29 14:52:53 -06:00
Mitchell Hashimoto
0006ca1d58 Merge pull request #1185 from mitchellh/cub-rw
terminal: cub with reverse wrap consumes pending wrap state as one
2023-12-29 12:49:36 -08:00
Mitchell Hashimoto
3e9a4ea234 terminal: cub with reverse wrap consumes pending wrap state as one
Related to #1184

See the updated website page and associated test.
2023-12-29 12:45:57 -08:00
Mitchell Hashimoto
884814eb03 Merge pull request #1184 from mitchellh/cub
terminal: cursor back should not reduce by one with pending wrap
2023-12-29 12:37:26 -08:00
Mitchell Hashimoto
fdd519f73b terminal: cursor back should not reduce by one with pending wrap
Fixes #1183

I'm not sure why the original logic was there. When I translated the
original test cases to shell and ran them in xterm, they did NOT match
what Ghostty expected. This updates the tests to match xterm and removes
this case. We can add back in more tests if/when we figure out under
what scenario this original logic was correct (if it ever was).
2023-12-29 12:34:33 -08:00
Mitchell Hashimoto
7815aeaa86 readme: misordered headers 2023-12-29 11:47:03 -08:00
Mitchell Hashimoto
5af5dbffaf update tester README to note friend invites, MIT, etc. 2023-12-29 11:46:21 -08:00
Mitchell Hashimoto
677cb05326 Merge pull request #1182 from mitchellh/command-path
config: validate that `command` can be found on the path
2023-12-29 11:41:19 -08:00
Mitchell Hashimoto
4ec2f50c1d config: validate that command can be found on the path 2023-12-29 11:22:34 -08:00
Matthew Winter
992888d4bd Ensure the cwd is not changed, whilst remaining a logon shell 2023-12-30 05:40:07 +11:00
Matthew Winter
9989436beb Ensure the shell environment passes the Login Shell test 2023-12-30 04:32:13 +11:00
Mitchell Hashimoto
b50ce6bb6a Merge pull request #1176 from tristan957/libadwaita
Use adw_application_new() instead of adw_init()
2023-12-29 09:11:21 -08:00
Mitchell Hashimoto
e43919cb9e apprt/gtk: stylistic changes to adwaita init 2023-12-29 09:10:49 -08:00
Matthew Winter
5e3e76bcae Modify the way the login shell is launched on macOS to reduce nesting 2023-12-30 03:51:16 +11:00
Mitchell Hashimoto
6532ff73a8 macos: verify inspector is not nil before sending it to draw 2023-12-29 07:53:20 -08:00
Mitchell Hashimoto
5cef3ced18 Merge pull request #1179 from mitchellh/keypad-maybe
input: only send keypad events for keypad application mode
2023-12-28 20:02:15 -08:00
Tristan Partin
41aa9ac2ff Use adw_application_new() instead of adw_init()
This will enable further libadwaita improvements in the future, but will
have no effect today.
2023-12-28 21:50:56 -06:00
Mitchell Hashimoto
c3fd37f687 Merge pull request #1178 from mitchellh/macos-restore
macos: invalid restorable state when surface is closed
2023-12-28 19:44:16 -08:00
Mitchell Hashimoto
40e882ff48 macos: invalid restorable state when surface is closed
Fixes #1177
2023-12-28 19:39:47 -08:00
Mitchell Hashimoto
f71c597037 Merge pull request #1174 from byildiz/main
Reorder menu items (File, Edit, View ...) like most of the other apps
2023-12-28 13:31:55 -08:00
Burak Yildiz
f3c6066be3 Reorder menu items (File, Edit, View ...) like most of the other apps 2023-12-28 21:43:24 +01:00
Mitchell Hashimoto
3b7dc97ad4 Merge pull request #1173 from mitchellh/release-entitlements
ci: explicitly sign our release entitlements on build
2023-12-28 10:38:22 -08:00
Mitchell Hashimoto
64e3cbf28c ci: explicitly sign our release entitlements on build
Fixes #1169
2023-12-28 10:37:45 -08:00
Mitchell Hashimoto
7fcd4233cd config: not that cursor-style with shell integration overwrites 2023-12-28 09:17:42 -08:00
Mitchell Hashimoto
276ff84583 Merge pull request #1172 from rockorager/delay_syscall
termio: delay repeated `waitpid` syscalls when killing children
2023-12-28 09:16:17 -08:00
Tim Culverhouse
eda76e105f termio: delay repeated waitpid syscalls when killing children
PR #1168 introduced a loop to kill all children. The `waitpid` call is
issued with the NOHANG flag, which means it returns immediately if no
child has exited. This has the effect that we can repeatedly run through
this loop making this syscall, flooding the system with calls and not
getting timely responses. On my system, this caused Ghostty to take ~30
seconds to close. In my attempts to debug, I added logging to the loop
which resolved the issue. To find out why, I added a loop counter and
found the loop would run > 70 million cycles while trying to close. By
adding logging, I introduced just enough delay in the loop cycle to
prevent whatever flooding of syscalls was happening. This reduced the
loop counter to ~2 cycles before closing.

Add a small delay to prevent syscall flooding.
2023-12-28 10:43:33 -06:00
Mitchell Hashimoto
c2a132c068 ci: remove macos unsigned releases 2023-12-27 22:25:38 -08:00
Mitchell Hashimoto
937e41bf79 Merge pull request #1168 from mitchellh/kill
termio: ensure we kill all the children without killing ourselves
2023-12-27 22:01:40 -08:00
Mitchell Hashimoto
e32c031588 termio: ensure we kill all the children without killing ourselves
Fixes #497

This commit resolves two bugs:

First, if a surface is created and destroyed too quickly, the child
process may not have called `setsid` yet (to set the process group). In
this case, `getpgid` returns Ghostty's process group and we were killing
ourselves. We now detect we're about to kill ourselves and wait for our
child to be ready to be killed.

Second, if the child calls setsid but is in the process of execve when
we send a killpg, then the child will be killed but any newly spawned
grandchildren will remain alive. To fix this, we moved the waitpid call
into a kill loop so we can repeatedly kill our child if we detect any
grandchildren are still alive.
2023-12-27 21:44:58 -08:00
Mitchell Hashimoto
1c68dd5b6c Merge pull request #1166 from mitchellh/macos-surface-init
macos: set surface tree on init in restore
2023-12-27 21:31:33 -08:00
Mitchell Hashimoto
0008fb0a27 macos: set surface tree on init in restore
This prevents an unnecessary SurfaceView from being created. Creating a
SurfaceView is very expensive because this starts multiple threads,
creates the pty, starts the pty process, etc.

Additionally, this was exposing what I believe to be #497 when restoring
state: a surface view was created and destroyed very quickly causing
hangs on some machines. This still needs to be resolved but the behavior
in this commit was still a bug anyways.
2023-12-27 20:12:46 -08:00
Mitchell Hashimoto
4f31af13ad Merge pull request #1165 from mitchellh/dangling-notification
macos: notifications use surface UUID for lookups
2023-12-27 09:02:43 -08:00
Mitchell Hashimoto
181cfa1350 macos: notifications use surface UUID for lookups
Fixes #1162
2023-12-27 08:49:12 -08:00
Mitchell Hashimoto
21db51ff9d input: only send keypad events for keypad application mode
Fixes #1099
2023-12-27 08:10:01 -08:00
Mitchell Hashimoto
d648daed6a Merge pull request #1164 from mitchellh/macos-about-select
macos: text in about window is selectable
2023-12-27 07:54:40 -08:00
Mitchell Hashimoto
789107ff1b macos: text in about window is selectable
Fixes #1163

I also fixed the AppIconImage from being 1024x1024 to much smaller so we
don't see as many artifacts in the downsize.
2023-12-27 07:53:28 -08:00
Mitchell Hashimoto
107f1b1050 Merge pull request #1161 from mitchellh/new-surface-uuid
macOS: restore focused split on app state restore
2023-12-26 14:53:00 -08:00
Mitchell Hashimoto
2aa7f12417 macos: increment restorable state version 2023-12-26 14:45:39 -08:00
Mitchell Hashimoto
98041940f0 macos: restore focused split on app restore 2023-12-26 14:45:27 -08:00
Mitchell Hashimoto
a321ef515d macos: assign unique UUID per surface, store in app state 2023-12-26 14:24:05 -08:00