Skip to content

Commit

Permalink
disable periodic SIGWINCH by default; can be enabled with GITSTATUS_S…
Browse files Browse the repository at this point in the history
…END_SIGWINCH=1
  • Loading branch information
romkatv committed Apr 9, 2019
1 parent 2b24168 commit c6b74d1
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions gitstatus.plugin.zsh
Original file line number Diff line number Diff line change
Expand Up @@ -223,12 +223,15 @@ function gitstatus_start() {
esac
}

local -i sigwinch_pid=-1
(( ! ${GITSTATUS_SEND_SIGWINCH:-0} )) || sigwinch_pid=$$

# We use `zsh -c` instead of plain {} or () to work around bugs in zplug. It hangs on startup.
zsh -xc "
${(q)daemon} \
--lock-fd=3 \
--sigwinch-pid=$$ \
--num-threads=$threads \
${(q)daemon} \
--lock-fd=3 \
--sigwinch-pid=$sigwinch_pid \
--num-threads=$threads \
--dirty-max-index-size=$max_dirty
echo -nE $'bye\x1f0\x1e'
" <&$req_fd >&$resp_fd 2>$log_file 3<$lock_file &!
Expand Down

0 comments on commit c6b74d1

Please sign in to comment.