简体   繁体   English

尝试构建工作区时 STS/Eclipse 权限被拒绝错误

[英]STS/Eclipse permission denied error when trying to build workspace

I am running STS4 which is a variant of eclipse for the spring framework in conjunction with maven.我正在运行 STS4,它是与 Maven 结合使用的 spring 框架的 eclipse 变体。 I am able to build my workspace only if I run:只有当我运行时,我才能构建我的工作区:

sudo mvn clean install

If I try to run the build from the STS IDE, I get permission denied error on multiple files.如果我尝试从 STS IDE 运行构建,我会收到多个文件的权限被拒绝错误。

I have tried changing permissions on the entire project folder and still get the same results.我尝试更改整个项目文件夹的权限,但仍然得到相同的结果。

How can I get STS to build the workspace as sudo, or what other way can I get this to work reliably from within the IDE?我怎样才能让 STS 以 sudo 的形式构建工作区,或者我可以通过什么其他方式让它在 IDE 中可靠地工作?

EDIT: I am using Mac OS编辑:我使用的是 Mac OS

Probally a unix permission error, when you builded the project with super user permission (sudo), maven has created some files that have root (the super user) as the owner.可能是unix权限错误,当您使用超级用户权限(sudo)构建项目时,maven创建了一些以root(超级用户)为所有者的文件。 Probally, you are running your STS without super user permission.可能是您在没有超级用户许可的情况下运行 STS。 So, when you try to build the project without super user permission (with your IDE, running normally), you do not have permission to replace current files (that ones that has root as the owner).因此,当您尝试在没有超级用户权限的情况下(使用您的 IDE,正常运行)构建项目时,您无权替换当前文件(那些以 root 为所有者的文件)。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM