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
Add zsh completions to homebrew formula #332
Comments
Pinging @carlfriedrich as the original master of the homebrew stuff. I'd love to learn how to run and test this stuff, if you want to document it somewhere I can help next time. |
@sandr01d I actually set up forgit in homebrew once and never updated it. I was planning to add a GitHub action to update it automatically with each release, just like we do with AUR, but I didn't have time for it, yet, and furthermore I don't have access to a Mac in order to test the homebrew stuff. |
Happy to investigate this. I think I can also try to get it automated. it'd be nice to have our freshest up all the time. |
Alright, there are multiple rounds we have to go through here, as our completions aren't exactly working still. I think we need to change them on our side of the fence. To get the ball rolling, I submitted a cleanup PR: This was mostly to get my feet wet in the homebrew world so I could do the meatier change of fixing the completions. Check it out if you get a chance. |
@cjappl Great, thanks for taking this over! |
@carlfriedrich could you walk me (an idiot, who doesn't understand zsh) how do use our completions? Like very explicitly:
I cannot get them to work, but I 100% expect user error. Please be as explicit as possible, as I don't have any zsh experience. What I have now: Git forgit is on my path and runs as expected:
following these instructions at the top of the completions:
I have an $fpath (no idea what that is) that looks like:
I have placed this file in
I have tried to source it:
I have tried to autocomplete, assuming I'll get something:
These files are not changed, I do not get suggested any flags for |
Pinging @sandr01d who implemented the zsh completions. |
@cjappl sounds like compsys (zsh's completion system) is not initialized. Let me walk you through the setup and try to provide a bit of background information that might come in handy. autoload -Uz compinit
compinit
should print a list of available commands. source /path/to/forgit.plugin.zsh
source /path/to/completions/git-forgit.zsh Let me know whether things are working out for you and whether anything I've provided is unclear and I will do my best to help sort it out. |
Thank you. Very helpful. Could you explain the difference between our two files: and Which file should be sourced? are the names important? Do they both need to be on EDIT: forgive me for not RTFM. From what I understand is that _git-forgit controls the sub command form, aka The other file, I have played around with this a bit in #340 |
Check list
Noticed the homebrew formula installs completions for bash, but not zsh. As I don't use homebrew myself, I currently don't have a setup to test this, maybe someone else is interested in doing this?
The text was updated successfully, but these errors were encountered: