mirror-ghostty/dist/linux
Mitchell Hashimoto 587f47a587
apprt/gtk-ng: clean up our single instance, new window interactions
This removes `launched-from` entirely and moves our `gtk-single-instance`
detection logic to assume true unless we detect CLI instead of assume
false unless we detect desktop/dbus/systemd.

The "assume true" scenario for single instance is desirable because
detecting a CLI instance is much more reliable.

Removing `launched-from` fixes an issue where we had a
difficult-to-understand relationship between `launched-from`,
`gtk-single-instance`, and `initial-window`. Now, only
`gtk-single-instance` has some hueristic logic. And `initial-window`
ALWAYS sends a GTK activation signal regardless of single instance or
not.

As a result, we need to be explicit in our systemd, dbus, desktop files
about what we want Ghostty to do, but everything works as you'd mostly
expect.

Now, if you put plain old `ghostty` in your terminal, you get a new
Ghostty instance. If you put it anywhere else, you get a GTK single
instance activation call (either creates a first instance or opens a new
window in the existing instance). Works for launchers and so on.
2025-09-05 10:17:17 -05:00
..
app.desktop.in apprt/gtk-ng: clean up our single instance, new window interactions 2025-09-05 10:17:17 -05:00
com.mitchellh.ghostty.metainfo.xml.in Correct AppStream metainfo XML, broken trailing tags 2025-06-26 13:37:20 -07:00
dbus.service.flatpak.in apprt/gtk-ng: clean up our single instance, new window interactions 2025-09-05 10:17:17 -05:00
dbus.service.in apprt/gtk-ng: clean up our single instance, new window interactions 2025-09-05 10:17:17 -05:00
ghostty_dolphin.desktop added exec permission back to dolphin action 2025-01-20 20:19:12 +01:00
ghostty_nautilus.py linux: add "Open in Ghostty" shortcut for nautilus 2025-01-08 13:49:32 +01:00
systemd.service.in apprt/gtk-ng: clean up our single instance, new window interactions 2025-09-05 10:17:17 -05:00