如何解决与rbenv相关的终端错误/消息

问题描述 投票:0回答:1

启动终端后,我一直收到以下错误/消息。在多次尝试安装sass之后,这开始发生(这本身就是另一个问题)。

此后,我已经卸载了rbenv。我正在运行osx el capitan。

-bash: ‘export: command not found
-bash: /Users/JO/.bash_profile: line 5: syntax error near unexpected token `('
-bash: /Users/JO/.bash_profile: line 5: `‘eval “export PATH="/Users/JO/.rbenv/shims:${PATH}" export RBENV_SHELL=bash source '/usr/local/Cellar/rbenv/1.1.2/libexec/../completions/rbenv.bash' command rbenv rehash 2>/dev/null rbenv() { local command command="${1:-}" if [ "$#" -gt 0 ]; then shift fi case "$command" in rehash|shell) eval "$(rbenv "sh-$command" "$@")";; *) command rbenv "$command" "$@";; esac }”’'

我对终端问题不屑一顾。因此,对此的任何帮助都将受到赞赏。干杯。

bash macos terminal osx-elcapitan rbenv
1个回答
0
投票

据说(Basic Github结帐,第2部分,根据您正在运行的终端,复制并超越以下选项之一:

对于Bash:echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bash_profile

对于Ubuntu:echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bashrc

对于Zshecho 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.zshrc

在上面检查您的日志,我看到您使用'eval,必须删除,然后仅放one of the options above

或者,您可以让rbenv医生看您错过的内容:

curl -fsSL https://github.com/rbenv/rbenv-installer/raw/master/bin/rbenv-doctor | bash

[不要忘记打开新终端以查看所做的更改。

© www.soinside.com 2019 - 2024. All rights reserved.