gf is incompatible with oh-my-zsh git plugin
gsilvapt opened this issue · 5 comments
Just ran the regular installation process (go build && mv gf /usr/bin/ && cat zsh-completion.zsh >> ~/.zshrc && source ~/.zshrc
) just fo find out gf wasn't working due to an alias I did not set up.
If you have oh-my-zsh and the git plugin activated (which I believe actually comes activated by default), then this plugin has an alias for gf
command, for git fetch.
Console output:
$ gf -list
error: unknown switch `l'
usage: git fetch [<options>] [<repository> [<refspec>...]]
or: git fetch [<options>] <group>
or: git fetch --multiple [<options>] [(<repository> | <group>)...]
or: git fetch --all [<options>]
... ... ...
This is because the plugin adds an alias for gf:
$ alias gf
gf='git fetch'
I have got around this by putting unalias gf
in by zshrc but if you use it, you could rename gf to something else
I'm not a zsh user, so thanks for clarifying what the issue is @Jab2870 :)
@gsilvapt I'm afraid I don't really want to rename my tool now that it's got more than a dozen or so people using it. Sorry!
My intention was clearly not to rename this tool but to report the issue and also have something added in the README
file or something to let other users know. If you don't find it relevant, I understand.
Ah! OK! Sorry I misunderstood! I'll add something to the readme now, thank you :)
Yea same problem here :)