-
Notifications
You must be signed in to change notification settings - Fork 2.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Auto-completion stop to work with Git version 2.18.0 #1792
Comments
Thank you for reporting! I can see the same. |
Wrap `git --list-cmds=others` command used by git built-in shell completions to add a list of hub custom commands. Fixes #1792
@mislav I'm still having this issue using hub 2.5.0:
|
It's working for me after install the new version of hub (2.5.0) with Homebrew. |
@davishmcclurg Unfortunately, the new workaround in hub 2.5.0 will only work when hub is aliased as # without alias
$ hub p
pull push
$ alias git=hub
$ hub p
pr pull pull-request push |
Ok, that works. Thanks @mislav! |
Gonna reopen this until alias is no longer needed |
I did set Environment
Should I talk about zsh-completion here? |
zsh-completion is not relevant. But whether you have the Git-provided hub folks: what do you think about extending |
Alias stops working for me recently.
|
Same here @ushuz
|
I get this with hub 2.12.0 and bash 3.2 on macOS: $ alias git=hub
$ hub pu
pull pull-request push @ushuz @arturoherrero Could you provide more information about your shell, OS, and how you installed hub and shell completions? Thanks |
Ah I see it now when I upgrade to git 2.22: $ hub pu
pull push git must have changed something again in how they organize their shell completions. I think it's too risky that we build on top of their completion script, but then again I have no other ideas on how to hook into git's completions to inject extra hub stuff. |
Hotfix
FYI: https://github.com/git/git/blob/7c20df8/contrib/completion/git-completion.bash#L1029 |
@yasuoza I suspect that will break some use cases because: https://github.com/git/git/blob/7c20df8/contrib/completion/git-completion.bash#L90 |
Just in case this saves anyone time - these tips may seem obvious, but so many people including myself have been struggling to get this working.
|
- Useful for creating GitHub pull requests from the command line. - Alias 'git' to 'hub' (mislav/hub#1792).
Neither works here. This is macOS 11.4 on a Silicon M1 machine. This is with home-brew in /opt/homebrew, and with
The hub version is the latest one from home-brew, I don't know why it is listed as "refs/heads/master", but apparently this is 2.14.2.
I had to disable asyncpreemptoff because of golang/go#42700 |
Also doesn't work with the very latest git version on home-brew (2.32.0). I accidentally also discovered that running |
I have this
when I tab on this
it gives
I don't know how to fix it I am using mac os silicon M1 When i remove alias
git working fine
hub gives me an error. I think this is related to zsh autocomplete but not sure how to solve it. |
I use macOS and Homebrew to install/update Git and hub.
After upgrade Git (
brew upgrade git
) from version2.17.1
to2.18.0
the auto-completion of the GitHub commands provided by hub (browse
,ci-status
,compare
, etc...) stop to work in Bash.Previous configuration with auto-completion working:
Current configuration with auto-completion not working:
I was able to reproduce the error in two different machines.
The text was updated successfully, but these errors were encountered: