安装 RVM 时出错:需要 BASH 3.2.25(您有 4.3.42(4)-release)
Error installing RVM: requiring BASH 3.2.25 (you have 4.3.42(4)-release)
我正在尝试安装 RVM,并且我有 BASH 的更新版本。我假设它需要 3.2.25 或更新的版本。我在网上看到一些关于它的 post,但它们都已过时或不再与当前代码相关。这是我在 cmd 中输入的内容(我有 Windows 10 pro)。
curl -L https://get.rvm.io | bash -s stable --autolibs=enabled --ruby --rails
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 184 100 184 0 0 143 0 0:00:01 0:00:01 --:--:-- 155
100 22865 100 22865 0 0 9566 0 0:00:02 0:00:02 --:--:-- 45730
Input file specified two times.
BASH 3.2.25 required (you have 4.3.42(4)-release)
检查 运行 时显示的错误 "Input file specified two times," 是 Windows 排序命令的输出。如果您 运行 此命令,它将显示 sort
命令的哪个实例正在 运行:
which sort
为确保始终使用正确的版本,请更改您的 PATH
以在任何 Windows 路径之前包含典型的 Bash 可执行路径 (/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin
)。或者,只需从 PATH
中删除 Windows 路径。
更改位置取决于您安装 Bash(Cygwin、git-bash 等)的方式,但通常是主目录中名为 .profile
或 .bash_profile
.
我的问题是 ~/.bash_profile,
因为你的头错了。
如果您正在使用:
export PATH=some/other/path:${PATH}
让我们改为:
export PATH=${PATH}:some/other/path
希望对您有所帮助!
我正在尝试安装 RVM,并且我有 BASH 的更新版本。我假设它需要 3.2.25 或更新的版本。我在网上看到一些关于它的 post,但它们都已过时或不再与当前代码相关。这是我在 cmd 中输入的内容(我有 Windows 10 pro)。
curl -L https://get.rvm.io | bash -s stable --autolibs=enabled --ruby --rails
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 184 100 184 0 0 143 0 0:00:01 0:00:01 --:--:-- 155
100 22865 100 22865 0 0 9566 0 0:00:02 0:00:02 --:--:-- 45730
Input file specified two times.
BASH 3.2.25 required (you have 4.3.42(4)-release)
检查 运行 时显示的错误 "Input file specified two times," 是 Windows 排序命令的输出。如果您 运行 此命令,它将显示 sort
命令的哪个实例正在 运行:
which sort
为确保始终使用正确的版本,请更改您的 PATH
以在任何 Windows 路径之前包含典型的 Bash 可执行路径 (/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin
)。或者,只需从 PATH
中删除 Windows 路径。
更改位置取决于您安装 Bash(Cygwin、git-bash 等)的方式,但通常是主目录中名为 .profile
或 .bash_profile
.
我的问题是 ~/.bash_profile, 因为你的头错了。 如果您正在使用:
export PATH=some/other/path:${PATH}
让我们改为:
export PATH=${PATH}:some/other/path
希望对您有所帮助!