If a user sets NO_CLOBBER, git-prompt.zsh is unhappy.
Minimal reproduction: in ~/.zshenv (with no other startup files)
setopt NO_CLOBBER
PS1='%v $(gitprompt)%#'
source ~/Downloads/src/git-prompt/git-prompt.zsh
Result:
_zsh_git_prompt_async_request:26: can't clobber parameter _ZSH_GIT_PROMPT_ASYNC_FD containing file descriptor 0
_zsh_git_prompt_async_request:41: file number expected
For the moment, I've fixed my problem by adding unsetopt NO_CLOBBER at the top of _zsh_git_prompt_async_request locally, but I wanted to let you know. (For what it's worth, I first tried adding emulate -L zsh at the top of git-prompt.zsh, but that caused other problems. At that point, I took the path of least resistance and just unset the one option.)
I overlooked a better solution, namely to add emulate -L zsh to the function that had a problem when NO_CLOBBER was set. See #49.
If a user sets
NO_CLOBBER, git-prompt.zsh is unhappy.Minimal reproduction: in ~/.zshenv (with no other startup files)
Result:
For the moment, I've fixed my problem by addingunsetopt NO_CLOBBERat the top of_zsh_git_prompt_async_requestlocally, but I wanted to let you know. (For what it's worth, I first tried addingemulate -L zshat the top of git-prompt.zsh, but that caused other problems. At that point, I took the path of least resistance and just unset the one option.)I overlooked a better solution, namely to add
emulate -L zshto the function that had a problem whenNO_CLOBBERwas set. See #49.