Output only newlines in the pty

This commit is contained in:
Eric Freese 2017-01-24 22:27:09 -07:00
parent 0337005eb0
commit e5a5b0c1e0
2 changed files with 6 additions and 0 deletions

View file

@ -12,6 +12,9 @@ _zsh_autosuggest_async_fetch_suggestion() {
_zsh_autosuggest_async_suggestion_server() { _zsh_autosuggest_async_suggestion_server() {
emulate -R zsh emulate -R zsh
# Output only newlines (not carriage return + newline)
stty -onlcr
while IFS='' read -r -d $'\0' prefix; do while IFS='' read -r -d $'\0' prefix; do
# Kill last bg process # Kill last bg process
kill -KILL %1 &>/dev/null kill -KILL %1 &>/dev/null

View file

@ -489,6 +489,9 @@ _zsh_autosuggest_async_fetch_suggestion() {
_zsh_autosuggest_async_suggestion_server() { _zsh_autosuggest_async_suggestion_server() {
emulate -R zsh emulate -R zsh
# Output only newlines (not carriage return + newline)
stty -onlcr
while IFS='' read -r -d $'\0' prefix; do while IFS='' read -r -d $'\0' prefix; do
# Kill last bg process # Kill last bg process
kill -KILL %1 &>/dev/null kill -KILL %1 &>/dev/null