凤凰框架安装失败
我试图在Linux Mint UMA上开始在Phoenix框架中开发 我正在运行Erlang OTP 22,Elixir 1.9 我遵循官方安装指南,问题是 - 我无法安装PHX_NEW,因为我已经过时了Elixir版本1.9
**(混合)您正在尝试运行:elixir v1.9.1上的phx_new,但它已在其Mix.exs文件中声明。exs文件仅支持elixir〜> 1.12
我尝试重新安装elixir / erlang多种方式,但没有任何改变
Im trying to start developing in Phoenix framework on Linux Mint Uma
and Im running Erlang OTP 22, Elixir 1.9
Im following the official installation guide and the problem is -- I cannot install phx_new since I have outdated Elixir version 1.9
** (Mix) You're trying to run :phx_new on Elixir v1.9.1 but it has declared in its mix.exs file it supports only Elixir ~> 1.12
I tried reinstalling elixir / erlang multiple ways, but nothing changes
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
在您的
mix.exs.exs
phoenix应用程序中的文件中,您有类似的内容:行:
表示运行应用程序所需的Elixir版本必须是:
请注意,Elixir 1.9.1不在该范围内。如果您想在应用程序中使用Elixir 1.9.1,请告诉Phoenix:
要找出系统认为已安装的Elixir和Erlang,请使用:
我使用 asdf 要安装不同版本的lixir/erlang并在版本之间切换。
In your
mix.exs
file inside your phoenix app, you have something like this:The line:
means the elixir version necessary to run your app must be:
Note that elixir 1.9.1 is not in that range. If you want to use elixir 1.9.1 in your app, then tell Phoenix that:
To find out what elixir and erlang your system thinks is installed, use:
I use asdf to install different versions of elixir/erlang and to switch between versions.
这是因为Elixir版本1.9.1< 1.12.0。在Elixir Interactive模式的命令行上键入
iex
,然后检查自己:version.compare(“ 1.9.1”,“ 1.12.0”)
。它将显示:lt
(小于)。解决方案是手动升级Erlang和Elixir。This is because Elixir version 1.9.1 < 1.12.0 . Type
iex
on the command line for the Elixir interactive mode and check for yourself:Version.compare("1.9.1", "1.12.0")
. It will show:lt
(less than). The solution is to upgrade Erlang and Elixir manually.