[英]IntelliJ & Maven - mvn command not found
I'm trying to build a drop wizard project created with IntelliJ.我正在尝试构建一个使用 IntelliJ 创建的放置向导项目。 when I run
当我跑步时
mvn package
I get我明白了
bash: mvn: command not found
I'm on a Mac and I'm following this tutorial: http://www.dropwizard.io/0.9.2/docs/getting-started.html我在 Mac 上,我正在关注本教程: http://www.dropwizard.io/0.9.2/docs/getting-started.html
According to IntelliJ documentation ( https://www.jetbrains.com/help/idea/2016.1/maven.html?origin=old_help )根据 IntelliJ 文档( https://www.jetbrains.com/help/idea/2016.1/maven.html?origin=old_help )
Maven integration is shipped with IntelliJ IDEA, and you do not need to perform any additional actions to install it.
Maven 集成随 IntelliJ IDEA 一起提供,您无需执行任何其他操作即可安装它。 You can start using it straight away for importing Maven projects, working with them and for running Maven goals.
您可以立即开始使用它来导入 Maven 项目,使用它们并运行 Maven 目标。
So I don't know what I'm suppose to do in order to use the command line Any idea?所以我不知道为了使用命令行我应该做什么知道吗?
Thanks谢谢
mvn is the command line tool for Maven. mvn是Maven的命令行工具。 See https://maven.apache.org/install.html for details on how to install it.
有关如何安装它的详细信息,请参阅https://maven.apache.org/install.html 。 Or as you are using a Mac if you use brew try using it to install the maven formula.
或者当您使用Mac时,如果您使用brew尝试使用它来安装maven公式。
If you have maven properly installed and you want to configure intelliJ terminal with a custom Terminal or if you want fix "command not found", follow these steps:如果您已正确安装 maven 并且您想使用自定义终端配置 intelliJ 终端,或者如果您想修复“找不到命令”,请按照下列步骤操作:
// The path you may have differs based on your OS, in example: "installationPath\Terminal Folder\bin\sh.exe --login" // 您的路径可能因您的操作系统而异,例如:“installationPath\Terminal Folder\bin\sh.exe --login”
I used git bash but technically it should work with every terminal.我使用了 git bash 但从技术上讲它应该适用于每个终端。 Do not forget to add --login after the *.exe
不要忘记在 *.exe 之后添加 --login
If it still doesn't work maybe you need to check:如果它仍然不起作用,您可能需要检查:
Insert the path of your maven bin folder, in example:插入 maven bin 文件夹的路径,例如:
Also insert the path of your jdk, in example:还要插入你的 jdk 的路径,例如:
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.