@@ -89,22 +89,22 @@ function __ghostty_setup --on-event fish_prompt -d "Setup ghostty integration"
89
89
# SSH integration
90
90
if test -n " $GHOSTTY_SSH_INTEGRATION "
91
91
# Cache file for tracking hosts with terminfo installed
92
- set -l _ghostty_cache_file (string join / (test -n " $GHOSTTY_RESOURCES_DIR " ; and echo " $GHOSTTY_RESOURCES_DIR " ; or echo " $HOME /.config/ghostty" ) " terminfo_hosts" )
92
+ set --local _ghostty_cache_file (string join / (test -n " $GHOSTTY_RESOURCES_DIR " ; and echo " $GHOSTTY_RESOURCES_DIR " ; or echo " $HOME /.config/ghostty" ) " terminfo_hosts" )
93
93
94
94
# Extract target host from SSH arguments
95
95
function _ghostty_get_ssh_target
96
- set -l target " "
97
- set -l skip_next false
96
+ set --local target " "
97
+ set --local skip_next " false"
98
98
99
99
for arg in $argv
100
100
if test " $skip_next " = " true"
101
- set skip_next false
101
+ set skip_next " false"
102
102
continue
103
103
end
104
104
105
105
# Skip flags that take arguments
106
- if string match -qr ' ^-[bcDEeFIiJLlmOopQRSWw]$' -- " $arg "
107
- set skip_next true
106
+ if string match -qr -- ' ^-[bcDEeFIiJLlmOopQRSWw]$' " $arg "
107
+ set skip_next " true"
108
108
continue
109
109
end
110
110
@@ -123,14 +123,14 @@ function __ghostty_setup --on-event fish_prompt -d "Setup ghostty integration"
123
123
124
124
# Check if host has terminfo installed
125
125
function _ghostty_host_has_terminfo
126
- set -l target $argv [1]
126
+ set --local target " $argv [1]"
127
127
test -f " $_ ghostty_cache_file" ; and grep -qFx " $target " " $_ ghostty_cache_file" 2> /dev/null
128
128
end
129
129
130
130
# Add host to terminfo cache
131
131
function _ghostty_cache_host
132
- set -l target $argv [1]
133
- set -l cache_dir (dirname " $_ ghostty_cache_file" )
132
+ set --local target " $argv [1]"
133
+ set --local cache_dir (dirname " $_ ghostty_cache_file" )
134
134
135
135
# Create cache directory if needed
136
136
test -d " $cache_dir " ; or mkdir -p " $cache_dir "
@@ -147,14 +147,14 @@ function __ghostty_setup --on-event fish_prompt -d "Setup ghostty integration"
147
147
chmod 600 " $_ ghostty_cache_file" 2> /dev/null
148
148
end
149
149
150
- # Wrap `ssh` command to provide Ghostty SSH integration.
150
+ # Wrap `ssh` command to provide Ghostty SSH integration
151
151
function ssh -d " Wrap ssh to provide Ghostty SSH integration"
152
152
switch " $GHOSTTY_SSH_INTEGRATION "
153
- case term-only
153
+ case " term-only"
154
154
_ghostty_ssh_term-only $argv
155
- case basic
155
+ case " basic"
156
156
_ghostty_ssh_basic $argv
157
- case full
157
+ case " full"
158
158
_ghostty_ssh_full $argv
159
159
case " *"
160
160
# Unknown level, fall back to basic
@@ -187,7 +187,7 @@ function __ghostty_setup --on-event fish_prompt -d "Setup ghostty integration"
187
187
end
188
188
189
189
# Execute with environment variables if any were set
190
- if test " $ (count $env_vars )" -gt 0
190
+ if test (count $env_vars ) -gt 0
191
191
env $env_vars ssh $argv
192
192
else
193
193
builtin command ssh $argv
@@ -196,7 +196,7 @@ function __ghostty_setup --on-event fish_prompt -d "Setup ghostty integration"
196
196
197
197
# Level: full - All features
198
198
function _ghostty_ssh_full
199
- set -l target (_ghostty_get_ssh_target $argv )
199
+ set --local target (_ghostty_get_ssh_target $argv )
200
200
201
201
# Check if we already know this host has terminfo
202
202
if test -n " $target " ; and _ghostty_host_has_terminfo " $target "
0 commit comments