shell-integration: append $GHOSTTY_BIN_DIR to $PATH

For consistency with the termio/Exec.zig implementation, we always
append to the PATH (lowest priority).
pull/8976/head
Jon Parise 2025-10-01 10:42:33 -04:00
parent 4989f92c71
commit 6f596ee7c3
2 changed files with 2 additions and 2 deletions

View File

@ -198,7 +198,7 @@
}
if (and (has-value $features path) (has-env GHOSTTY_BIN_DIR)) {
if (not (has-value $paths $E:GHOSTTY_BIN_DIR)) {
set paths = [$E:GHOSTTY_BIN_DIR $@paths]
set paths = [$@paths $E:GHOSTTY_BIN_DIR]
}
}
if (and (has-value $features sudo) (not-eq "" $E:TERMINFO) (has-external sudo)) {

View File

@ -63,7 +63,7 @@ function __ghostty_setup --on-event fish_prompt -d "Setup ghostty integration"
# Add Ghostty binary to PATH if the path feature is enabled
if contains path $features; and test -n "$GHOSTTY_BIN_DIR"
fish_add_path "$GHOSTTY_BIN_DIR"
fish_add_path --append "$GHOSTTY_BIN_DIR"
end
# When using sudo shell integration feature, ensure $TERMINFO is set