I get the following in including MacPorts' Bash tab completion to Zsh
我将以下内容包括MacPorts的Bash选项卡完成到Zsh
/opt/local/etc/bash_completion:[:48: unrecognized condition: `2'
[ -- cut -- ]
/opt/local/etc/bash_completion:[:62: unrecognized condition: `2'
/opt/local/etc/bash_completion:69: command not found: shopt
[ -- cut -- ]
/opt/local/etc/bash_completion:3015: command not found: complete
/opt/local/etc/bash_completion:3062: parse error near `&&'
How can you have MacPorts' tab completion in Zsh?
你怎么能在Zsh中完成MacPorts的标签?
2 个解决方案
#1
You might want to try zsh completion for zsh. bash_completion
is for Bash, surprisingly enough.
您可能想为zsh尝试zsh完成。 bash_completion适用于Bash,令人惊讶的是。
edit It sounds like you might be looking specifically for completion support for the port
command. It looks like the MacPorts zsh
package has a +mp_completion
variant that will install completion for the port
command:
编辑听起来你可能正在寻找port命令的完成支持。看起来MacPorts zsh包有一个+ mp_completion变体,它将为port命令安装完成:
sudo port install zsh +mp_completion
#2
Waking up that old question I just found doing some researchs to mention the wonderful oh-my-zsh utility intended for OSX that brings easily tab completion to port amongst others and also many many other nice stuff. A must have imho :)
唤醒那个老问题我刚刚做了一些研究,提到了用于OSX的精彩的oh-my-zsh实用程序,它可以轻松地将标签完成移植到其他端口以及许多其他很好的东西。一定要有imho :)
#1
You might want to try zsh completion for zsh. bash_completion
is for Bash, surprisingly enough.
您可能想为zsh尝试zsh完成。 bash_completion适用于Bash,令人惊讶的是。
edit It sounds like you might be looking specifically for completion support for the port
command. It looks like the MacPorts zsh
package has a +mp_completion
variant that will install completion for the port
command:
编辑听起来你可能正在寻找port命令的完成支持。看起来MacPorts zsh包有一个+ mp_completion变体,它将为port命令安装完成:
sudo port install zsh +mp_completion
#2
Waking up that old question I just found doing some researchs to mention the wonderful oh-my-zsh utility intended for OSX that brings easily tab completion to port amongst others and also many many other nice stuff. A must have imho :)
唤醒那个老问题我刚刚做了一些研究,提到了用于OSX的精彩的oh-my-zsh实用程序,它可以轻松地将标签完成移植到其他端口以及许多其他很好的东西。一定要有imho :)