mirror of
https://github.com/zsh-users/zsh-autosuggestions.git
synced 2024-12-28 15:14:51 +08:00
little cleanup
This commit is contained in:
parent
16666da488
commit
40bb2e7804
|
@ -65,14 +65,13 @@ _zsh_autosuggest_async_recreate_pty() {
|
|||
# Start a new pty running the server function
|
||||
zpty -b $ZSH_AUTOSUGGEST_PTY_NAME "_zsh_autosuggest_async_suggestion_server _zsh_autosuggest_strategy_$ZSH_AUTOSUGGEST_STRATEGY"
|
||||
|
||||
# Store the fd so we can destroy this pty later
|
||||
# Store the fd so we can remove the handler later
|
||||
if (( REPLY )); then
|
||||
_ZSH_AUTOSUGGEST_PTY_FD=$REPLY
|
||||
else
|
||||
_ZSH_AUTOSUGGEST_PTY_FD=$zptyfd
|
||||
fi
|
||||
|
||||
|
||||
# Set up input handler from the pty
|
||||
zle -F $_ZSH_AUTOSUGGEST_PTY_FD _zsh_autosuggest_async_suggestion_ready
|
||||
}
|
||||
|
|
|
@ -579,14 +579,13 @@ _zsh_autosuggest_async_recreate_pty() {
|
|||
# Start a new pty running the server function
|
||||
zpty -b $ZSH_AUTOSUGGEST_PTY_NAME "_zsh_autosuggest_async_suggestion_server _zsh_autosuggest_strategy_$ZSH_AUTOSUGGEST_STRATEGY"
|
||||
|
||||
# Store the fd so we can destroy this pty later
|
||||
# Store the fd so we can remove the handler later
|
||||
if (( REPLY )); then
|
||||
_ZSH_AUTOSUGGEST_PTY_FD=$REPLY
|
||||
else
|
||||
_ZSH_AUTOSUGGEST_PTY_FD=$zptyfd
|
||||
fi
|
||||
|
||||
|
||||
# Set up input handler from the pty
|
||||
zle -F $_ZSH_AUTOSUGGEST_PTY_FD _zsh_autosuggest_async_suggestion_ready
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user