Cygwin 流浪者放弃';cygpath';在路径中未找到流浪汉
我安装了流浪者,流浪者免疫系统运行良好。当我现在运行Vagrant up时,我得到以下错误:Cygwin 流浪者放弃';cygpath';在路径中未找到流浪汉,cygwin,vagrant,vagrant-windows,Cygwin,Vagrant,Vagrant Windows,我安装了流浪者,流浪者免疫系统运行良好。当我现在运行Vagrant up时,我得到以下错误: The executable 'cygpath' Vagrant is trying to run was not found in the %PATH% variable. This is an error. Please verify this software is installed and on the path. 我使用cygwin作为终端,我有windows 8,我在环境变量的路径中放置
The executable 'cygpath' Vagrant is trying to run was not
found in the %PATH% variable. This is an error. Please verify
this software is installed and on the path.
我使用cygwin作为终端,我有windows 8,我在环境变量的路径中放置了C:\cygwin64\bin
我的问题是,当我指定了cygwin bin的路径时,为什么会收到此错误消息
谢谢 我假设您已经安装了Cygwin,只需将Cygwin的路径(通常是c:\Cygwin\bin\Cygwin.exe)添加到shell%path%变量中,您就可以开始了
- Ctrl-X=>系统=>高级设置=>变量
- 重新启动Powershell/Cmd窗口
重新启动shell,就可以开始了。我的解决方案是创建一个小的包装脚本,
vagrant.bat
:
@setlocal
@set PATH=C:\HashiCorp\Vagrant\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem
@vagrant %*
@endlocal
vagrant.bat
文件位于我的PATH
中的第一个目录中。您是否检查了给定的路径是否在PATH变量中?您是否尝试打印它以查看结果?您是否可以将p ENV['PATH']
添加到您的Vagrant文件中,并确保会话中使用的路径是您设置的路径,如果您添加了该路径,您应该会看到C:\cygwin64\bin
,这实际上是我的问题。我想这可能是因为我在过去安装了流浪者,或者在我的道路上乱搞。无论如何,从路径中删除cygwin后,Vagrant运行时没有问题。路径是文件夹,而不是可执行文件。正确的路径应该是以“\bin\”结尾的路径。