9911 Commits

Author SHA1 Message Date
Ken VanDine
725488e1a2 Improved environment handling to ensure the snap will work across
distros and unset all SNAP environment variables that could leak at
runtime
2025-02-15 07:06:40 -08:00
Ken VanDine
0acf82bb9c Use patch-rpath which improves our cross distro support 2025-02-15 07:06:40 -08:00
Mitchell Hashimoto
9944fd5958 ci: temporary apt installs required for namespace 2025-02-15 07:06:40 -08:00
Ken VanDine
e7d4daa7c1 Removed duplicated stage-packages 2025-02-15 07:06:40 -08:00
Ken VanDine
5de0e775cb Don't stage shells 2025-02-15 07:06:40 -08:00
Ken VanDine
301fdff58f enable-patchelf is more repliable for classic snaps 2025-02-15 07:06:40 -08:00
Ken VanDine
99c7abb43a Set GHOSTTY_RESOURCES_DIR 2025-02-15 07:06:40 -08:00
Ken VanDine
a85de40710 Exit with error if building for unsupported arch 2025-02-15 07:06:40 -08:00
Ken VanDine
e174fb2748 no-patchelf for DRI and tidy up the mesa bits 2025-02-15 07:06:40 -08:00
Ken VanDine
403eab2cf0 Stage gnome-text-editor to open configuration, this makes it more
reliable across more distros as a classic snap.
2025-02-15 07:06:40 -08:00
Ken VanDine
bdafc2227c Drop patchelf 2025-02-15 07:06:40 -08:00
Ken VanDine
c9cafd3051 Enable patch-elf for libs part 2025-02-15 07:06:40 -08:00
Ken VanDine
48f94e6fcc Stage more depends to ensure we aren't getting leaks from the host 2025-02-15 07:06:40 -08:00
Ken VanDine
43b2e43a11 EGL fixes, ensure necessary env variables are set to isolate
dependencies from the host
2025-02-15 07:06:40 -08:00
Ken VanDine
8dffe3450c CRAFT_TARGET_ARCH is deprecated, use CRAFT_ARCH_BUILD_FOR 2025-02-15 07:06:40 -08:00
Ken VanDine
ae953b5f10 Ensure LD_LIBRARY_PATH is set appropriately 2025-02-15 07:06:40 -08:00
Mitchell Hashimoto
c7635201ab Add snap to nix, add arm64 builders 2025-02-15 07:06:40 -08:00
Ken VanDine
c35ca1e87f Set a more meaningful version for the snap 2025-02-15 07:06:40 -08:00
Ken VanDine
d06d6796c5 Changed shebang in launcher script 2025-02-15 07:06:40 -08:00
Ken VanDine
e6c9dc7040 Only run snap workflow on push and PR 2025-02-15 07:06:40 -08:00
Ken VanDine
5d0dde57f9 Don't stage shells 2025-02-15 07:06:40 -08:00
Ken VanDine
d0108416d0 enable-patchelf is more repliable for classic snaps 2025-02-15 07:06:40 -08:00
Ken VanDine
71297870cf Set GHOSTTY_RESOURCES_DIR 2025-02-15 07:06:40 -08:00
Ken VanDine
fcde494440 Install bash-completion 2025-02-15 07:06:40 -08:00
Ken VanDine
b7bd8444c7 Exit with error if building for unsupported arch 2025-02-15 07:06:40 -08:00
Ken VanDine
2b2b3c5b3b Set source-type for launcher dir 2025-02-15 07:06:40 -08:00
Ken VanDine
818c81282b Added snap build workflow 2025-02-15 07:06:40 -08:00
Ken VanDine
f0842c5599 Added snap packaging 2025-02-15 07:06:40 -08:00
Jeffrey C. Ollie
2d0940f6ae gtk: require libadwaita (#5749)
This commit removes support for building without libadwaita. (Y'all knew
that I just had this sitting in my back pocket). This will need some
serious review to ensure that we haven't lost any functionality.
2025-02-15 09:04:11 -06:00
Tim Culverhouse
f1f1120749 termio: use modified backend (#5776)
In Termio.init, we make a copy of backend and modify it by calling
initTerminal. However, we used the original in the struct definition.
This lead to the pty being opened with a size 0,0.
2025-02-14 22:57:50 -06:00
Mitchell Hashimoto
c1ff382e97 core: add env config option (#5309)
Fixes #5257

Specify environment variables to pass to commands launched in a terminal
surface. The format is `env=KEY=VALUE`.

`env = foo=bar`
`env = bar=baz`

Setting `env` to an empty string will reset the entire map to default
(empty).

`env =`

Setting a key to an empty string will remove that particular key and
corresponding value from the map.

`env = foo=bar`
`env = foo=`

will result in `foo` not being passed to the launched commands. Setting
a key multiple times will overwrite previous entries.

`env = foo=bar`
`env = foo=baz`

will result in `foo=baz` being passed to the launched commands.

These environment variables _will not_ be passed to commands run by
Ghostty for other purposes, like `open` or `xdg-open` used to open URLs
in your browser.
2025-02-14 20:55:51 -08:00
Tim Culverhouse
29f25ae474 termio: prevent responses to non-query OSC 21 sequences (#5770)
The Ghostty implementation of OSC 21 (Kitty color protocol) currently
responds to *all* OSC 21 sequences. It should not respond to a set, nor
a reset command. Fix the implementation so that we only respond if a
query was received.
2025-02-14 22:50:03 -06:00
Jeffrey C. Ollie
c7971b562e core: add env config option
Fixes #5257

Specify environment variables to pass to commands launched in a terminal
surface. The format is `env=KEY=VALUE`.

`env = foo=bar`
`env = bar=baz`

Setting `env` to an empty string will reset the entire map to default
(empty).

`env =`

Setting a key to an empty string will remove that particular key and
corresponding value from the map.

`env = foo=bar`
`env = foo=`

will result in `foo` not being passed to the launched commands.
Setting a key multiple times will overwrite previous entries.

`env = foo=bar`
`env = foo=baz`

will result in `foo=baz` being passed to the launched commands.

These environment variables _will not_ be passed to commands run by Ghostty
for other purposes, like `open` or `xdg-open` used to open URLs in your
browser.
2025-02-14 20:50:01 -08:00
Tim Culverhouse
b7009202ce termio: use modified backend
In Termio.init, we make a copy of backend and modify it by calling
initTerminal. However, we used the original in the struct definition.
This lead to the pty being opened with a size 0,0.
2025-02-14 22:44:27 -06:00
Jeffrey C. Ollie
25c5ecf553 gtk: require libadwaita
This commit removes support for building without libadwaita.
2025-02-14 21:49:51 -06:00
Tim Culverhouse
09fbf096d3 termio: prevent responses to non-query OSC 21 sequences
The Ghostty implementation of OSC 21 (Kitty color protocol) currently
responds to *all* OSC 21 sequences. It should not respond to a set, nor
a reset command. Fix the implementation so that we only respond if a
query was received.
2025-02-14 18:55:26 -06:00
Mitchell Hashimoto
b975f1e860 cli: disable +boo on non-desktop platforms due to lack of tty 2025-02-14 15:14:05 -08:00
Mitchell Hashimoto
8c4b0f815d prettier 2025-02-14 14:54:59 -08:00
Mitchell Hashimoto
4e8e2d9796 nix: snapcraft should only be installed on Linux 2025-02-14 14:52:36 -08:00
Ken VanDine
90ce5b75f1 Simplified setting snap version 2025-02-14 14:52:08 -08:00
Ken VanDine
fd9cbde3d8 Merge remote-tracking branch 'upstream/main' into add_snap_package 2025-02-14 14:52:08 -08:00
Ken VanDine
b0edda4b69 Updated stage packages 2025-02-14 14:52:08 -08:00
Ken VanDine
bbd279bb4f Merge branch 'ghostty-org:main' into add_snap_package 2025-02-14 14:52:08 -08:00
Ken VanDine
bdbf30dc96 Merge branch 'ghostty-org:main' into add_snap_package 2025-02-14 14:52:08 -08:00
Ken VanDine
a111b3f96f Per PR review feedback, this is the more "ziggy" way of doing the check for environment variable. 2025-02-14 14:52:08 -08:00
Ken VanDine
f239df59ca Clean up environment variable while launching the shell 2025-02-14 14:52:08 -08:00
Ken VanDine
c036eb2444 Unset environment varies set by the snap 2025-02-14 14:52:08 -08:00
Ken VanDine
cee189de11 Only export XDG_CONFIG_HOME and XDG_DATA_HOME if they aren't already set 2025-02-14 14:52:08 -08:00
Ken VanDine
d2f82b2e40 Stage libglib2.0-0t64 to insure we don't mix in the host's lib 2025-02-14 14:52:08 -08:00
Ken VanDine
3e669fc4bb Improved environment handling to ensure the snap will work across
distros and unset all SNAP environment variables that could leak at
runtime
2025-02-14 14:52:08 -08:00