Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Strange behavior about option completion of `git push`



Hello,

I use zsh 5.8 on some OSes (CentOS, Cygwin, Debian, FreeBSD, etc.) and
found strange behavior about option completion of `git push`.

At first let's type `git push --r` and hit TAB. Then it is completed
as `git push --re`. Options of `git push` that start with `--r` are
`--receive-pack`, `--recurse-submodules` and `--repo` and all of them
start with `--re`. So it is reasonable that completion works as above.

Next let's type `git push --f' and hit TAB. In this case options that
start with `--f' are `--follow-tags`, `--force` and
`--force-with-lease` and all of them start with `--fo`. So expected
behavior is that it will be completed as `git push --fo`. But what
really happens is that there is no change after TAB is hit.

I checked definition of `_git-push` function in
/usr/share/zsh/5.8/functions/Completion/Unix/_git but didn't find the
source of the difference.

Would someone please explain why such differnce happens?

Best Regards.

---
Yasuhiro KIMURA




Messages sorted by: Reverse Date, Date, Thread, Author