更新到 Catalina 后,从终端运行 mvn clean install
时出现以下错误:
The goal you specified requires a project to execute but there is no POM in this directory (/private/var/folders/xs/lgy9yxv501xcvnqr_zhg85wr0000gn/T/hsperfdata_user1). Please verify you invoked Maven from the correct directory.
当前目录包含一个pom.xml和一个有效的项目
user1@xyz project1 % pwd
/Users/user1/Documents/project/project1
user1@xyz project1 % ls
README.md pom.xml project1-service
我也尝试过mvn clean install -f pom.xml
。这将出现错误:
The project (/Users/user1/Documents/project/project1/pom.xml) has 1 error
[ERROR] Non-readable POM /Users/user1/Documents/project/project1/pom.xml: /Users/user1/Documents/project/project1/pom.xml (Operation not permitted)
这在 InteliJ 的终端上运行得很好。 知道发生了什么吗?
最佳答案
我最终做的是系统偏好设置->安全和隐私->完整磁盘访问
并在那里添加终端。显然,使用 Catalina,您必须手动授予访问用户文件的应用程序的访问权限。
关于macos - macOS Catalina 更新 : there is no POM in this directory 后,Maven 从终端停止工作,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/58482494/