[英]Replacing an old version of ghc (installed with choco) with the newest ghc (installed with ghcup)
当 choco 是推荐的安装选项时,我安装了 ghc 8.10.1(在 Windows 10 上)。 现在我想更新 ghc,听说 ghcup 是新的首选安装方式。 我按照说明使用了 ghcup,据我所知,该过程成功结束,没有错误。
这是ghcup list
的一部分:
X ghc 8.10.1 base-4.14.0.0
X ghc 8.10.2 base-4.14.1.0
X ghc 8.10.3 base-4.14.1.0
X ghc 8.10.4 base-4.14.1.0
X ghc 8.10.5 base-4.14.2.0
X ghc 8.10.6 base-4.14.3.0
IS ghc 8.10.7 recommended,base-4.14.3.0
X ghc 9.0.1 base-4.15.0.0
X ghc 9.0.2 base-4.15.1.0
X ghc 9.2.1 base-4.16.0.0
X ghc 9.2.2 base-4.16.1.0
X ghc 9.2.3 latest,base-4.16.2.0
但是, ghc --version
仍然是 8.10.1。 安装可能在哪里出错,我该怎么做才能获得所有内容的最新版本(包括 cabal 和 stack)?
通过将C:\ghcup\bin
添加到 Path 并将其移动到顶部来解决此问题。 似乎我已经安装了所有东西 - 它只是没有添加到路径中。
我想与其将新路径移到顶部,我可以删除旧路径,但我不确定需要删除什么,也不想冒险删除任何有用的东西。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.