开发者

m2eclipse workspace resolution

开发者 https://www.devze.com 2022-12-27 14:18 出处:网络
I am using m2eclipse for managing maven projects in eclipse. It seems that in the previous release that I was using (0.9.8) the w开发者_StackOverflow社区orkspace resolution did not work at all, but ri

I am using m2eclipse for managing maven projects in eclipse. It seems that in the previous release that I was using (0.9.8) the w开发者_StackOverflow社区orkspace resolution did not work at all, but right now it also does not work quite as I would expect. Namely, when the "resolve dependencied from workspace" setting for a project is not checked, the project turns red and cannot be build. The message says: artifact xxx x.y-SNAPSHOT cannot be found int local repository (or something to that extent). The trouble is that m2eclipse is putting information about workspace project into my local repo. Is there a way to change this behaviour?

P.S. The workaround for this is to close the xxx project, then m2eclipse resolved the dependency to whatever version I've had previously in the local repository (i.e. the non-snapshot version).

P.S.2 screenshots showing what I have in the local repo:

  • Maven repos in eclipse

alt text http://img96.imageshack.us/img96/1498/mvnrepos.png

  • filesystem versions of the artifact in question

alt text http://img155.imageshack.us/img155/2999/versions.png

  • what is in the snapshot dir:

alt text http://img72.imageshack.us/img72/120/snapshotq.png


It seems that in the previous release that I was using (0.9.8) the workspace resolution did not work at all, but right now it also does not work quite as I would expect.

That's not what I'm experiencing. I have a project that has a dependency on another project and that is currently using workspace resolution:

alt text http://img180.imageshack.us/img180/9454/screenshot007l.png

If I uncheck Resolve dependencies from Workspace projects (under Properties > Maven) and apply the change, my build path becomes:

alt text http://img704.imageshack.us/img704/8869/screenshot007zh.png

The dependency is changed into a binary dependency as expected.


OK, for now the answer for me has been to downgrade to version 0.9.8, in which the plugin does not mess with the local repo.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号