无法从命令行 运行 MiniZinc - 即使在将安装位置添加到 PATH 之后
Unable to run MiniZinc from command line - Even after adding installation location to PATH
最初,我遇到错误:minizinc is not recognized as an internal or external command, operable program or batch file.
when 运行 minizinc mzn-cbc model.mzn data.mzn
in the Git CMD.
后来,按照 https://github.com/MiniZinc/libminizinc/issues/213 with suggestions from https://groups.google.com/forum/#!topic/minizinc/IFpUM_TSNGU 中的说明,我做了: export PATH=$PATH:{MINIZINC}
其中 {MINIZINC}
是安装位置。但是,我的终端返回了错误:'export' is not recognized as an internal or external command, operable program or batch file.
当我在 windows 命令提示符下尝试 运行 时也会发生这种情况。
有办法解决这个问题吗?
如果有帮助,安装 MiniZinc 的文件夹在我的电脑上看起来是这样的:
恐怕 GitHub 问题中给出的说明仅适用于 bash 和派生 shell。默认情况下 Windows 使用批处理。要更改在 Windows 上调用的 PATH 系统变量,您需要采取不同的步骤。它们在这里解释:https://java.com/en/download/help/path.xml
最初,我遇到错误:minizinc is not recognized as an internal or external command, operable program or batch file.
when 运行 minizinc mzn-cbc model.mzn data.mzn
in the Git CMD.
后来,按照 https://github.com/MiniZinc/libminizinc/issues/213 with suggestions from https://groups.google.com/forum/#!topic/minizinc/IFpUM_TSNGU 中的说明,我做了: export PATH=$PATH:{MINIZINC}
其中 {MINIZINC}
是安装位置。但是,我的终端返回了错误:'export' is not recognized as an internal or external command, operable program or batch file.
当我在 windows 命令提示符下尝试 运行 时也会发生这种情况。
有办法解决这个问题吗?
如果有帮助,安装 MiniZinc 的文件夹在我的电脑上看起来是这样的:
恐怕 GitHub 问题中给出的说明仅适用于 bash 和派生 shell。默认情况下 Windows 使用批处理。要更改在 Windows 上调用的 PATH 系统变量,您需要采取不同的步骤。它们在这里解释:https://java.com/en/download/help/path.xml