我在64位Windows 7中安装了luarocks,并且所有内容都安装正确,但是当我尝试运行luarocks时出现以下错误:
'pwd' is not recognized as an internal or external command,
operable program or batch file.
C:\Program Files (x86)\Lua\5.1\lua: ... Files (x86)\Lua\5.1\lua/luarocks\fs\win3
2\tools.lua:24: attempt to index local 'directory' (a nil value)
stack traceback:
... Files (x86)\Lua\5.1\lua/luarocks\fs\win32\tools.lua:24: in function
'command_at'
... Files (x86)\Lua\5.1\lua/luarocks\fs\win32\tools.lua:125: in function
<... Files (x86)\Lua\5.1\lua/luarocks\fs\win32\tools.lua:124>
(tail call): ?
... Files (x86)\Lua\5.1\lua/luarocks\fs\win32\tools.lua:147: in function
'make_dir'
...am Files (x86)\Lua\5.1\lua\luarocks\command_line.lua:30: in function
'is_writable'
...am Files (x86)\Lua\5.1\lua\luarocks\command_line.lua:76: in function
'run_command'
C:\Program Files (x86)\Lua\5.1\luarocks.lua:20: in main chunk
[C]: ?
'"lua5.1"' is not recognized as an internal or external command,
operable program or batch file.
我真的不确定自己做错了什么,而且我已经在互联网上搜索答案,并且什么也没找到。
答案 0 :(得分:0)
我将tools目录添加到了我的Windows Path变量,这解决了这个问题。由于其他原因,我仍然无法让luarocks工作,但我会在另外的问题上发布这些问题。