You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Eugeny N Dzhurinsky <bo...@redwerk.com> on 2008/09/22 17:39:41 UTC

eclipse plugin, resolve dependencies to the projects in the workspace

Hello, everybody!

I have the project A, which depends on the project B, both of the projects are
located in the same workspace.

When generating the eclipse project files for the project A, the project B
reference is being taken from the repository as a JAR file. 

What I want is to include the project B as a project reference for the project
A, so when the project A is opened in the Eclipse, the project B is opened as
well as a dependency, and all changes in the project B are reflected in the
project A (for example, if some interface contract was changed in the project
B, the corresponding files in the project A will contain errors, or changes in
the project A with refactoring will be merged to the project B as well).

I found there is the property "workspace" described in
http://maven.apache.org/plugins/maven-eclipse-plugin/eclipse-mojo.html#workspace,
however neither using it as mvn eclipse:eclipse -Dworkspace=/home/user/workspace, 
nor specifying it in the plugin configuration did not give the desired
results, and the project B is still referenced as a JAR file in the local
repository.

Do I miss something?

Thank you!

-- 
Eugene N Dzhurinsky

Re: eclipse plugin, resolve dependencies to the projects in the workspace

Posted by Eugene Kuleshov <eu...@md.pp.ru>.

Eugeny N Dzhurinsky-2 wrote:
> 
> On Tue, Sep 23, 2008 at 12:00:39PM +0300, N Dzhurinsky wrote:
>> >   Out of curiosity, why don't you use Maven IDe integration, such as
>> > m2eclipse? http://m2eclipse.codehaus.org/
>> 
>> I just tried it and I was really impressed of it's capabilities. Many
>> thanks!
> 
> After a time of using it I found for some reason it hangs the workspace
> building - it shows it is trying to compile a class for a while (I was
> waiting for 5 or 10 minutes). I removed the m2eclipse plugin - and
> everything works fine.
> 
> Do you have any ideas why is it and how to fix it? I am using Eclipse 3.4
> if
> that matters.
> 

  You may want to check Eclipse's Progress view and Maven console to see
what m2eclipse is doing.
  If that does not help, please report a bug in project bug tracker [1] at
and provide thread dump [2] when build hangs for your project. Also clarify
what "trying to compile a class" exactly mean (did you run Project/Clean or
launched Maven from Run as.. / Maven shortcut).
  Also, it is better to discuss issues specific to m2eclipe in its own
mailing list [3] or Eclipse newsgroups [4].

  Thanks

  Eugene

[1] http://jira.codehaus.org/browse/MNGECLIPSE
[2]
http://docs.codehaus.org/display/M2ECLIPSE/Project+FAQ#ProjectFAQ-threadDump
[3] http://m2eclipse.codehaus.org/mail-lists.html
[4]
http://www.eclipse.org/newsportal/thread.php?group=eclipse.technology.m2e
-- 
View this message in context: http://www.nabble.com/eclipse-plugin%2C-resolve-dependencies-to-the-projects-in-the-workspace-tp19610981p19841133.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: eclipse plugin, resolve dependencies to the projects in the workspace

Posted by Eugeny N Dzhurinsky <bo...@redwerk.com>.
On Tue, Sep 23, 2008 at 12:00:39PM +0300, Eugeny N Dzhurinsky wrote:
> >   Out of curiosity, why don't you use Maven IDe integration, such as
> > m2eclipse? http://m2eclipse.codehaus.org/
> 
> I just tried it and I was really impressed of it's capabilities. Many thanks!

After a time of using it I found for some reason it hangs the workspace
building - it shows it is trying to compile a class for a while (I was waiting
for 5 or 10 minutes). I removed the m2eclipse plugin - and everything works
fine.

Do you have any ideas why is it and how to fix it? I am using Eclipse 3.4 if
that matters.

Thank you!

-- 
Eugene N Dzhurinsky

Re: eclipse plugin, resolve dependencies to the projects in the workspace

Posted by Eugeny N Dzhurinsky <bo...@redwerk.com>.
On Mon, Sep 22, 2008 at 01:47:13PM -0700, Eugene Kuleshov wrote:
> 
> 
> Eugeny N Dzhurinsky-2 wrote:
> > 
> > I have the project A, which depends on the project B, both of the projects
> > are
> > located in the same workspace.
> > ...
> > I found there is the property "workspace" described in
> > http://maven.apache.org/plugins/maven-eclipse-plugin/eclipse-mojo.html#workspace,
> > however neither using it as mvn eclipse:eclipse
> > -Dworkspace=/home/user/workspace, 
> > nor specifying it in the plugin configuration did not give the desired
> > results, and the project B is still referenced as a JAR file in the local
> > repository.
> > 
> > Do I miss something?
> > 
> 
>   Out of curiosity, why don't you use Maven IDe integration, such as
> m2eclipse? http://m2eclipse.codehaus.org/

I just tried it and I was really impressed of it's capabilities. Many thanks!

-- 
Eugene N Dzhurinsky

Re: eclipse plugin, resolve dependencies to the projects in the workspace

Posted by Eugene Kuleshov <eu...@md.pp.ru>.

Eugeny N Dzhurinsky-2 wrote:
> 
> I have the project A, which depends on the project B, both of the projects
> are
> located in the same workspace.
> ...
> I found there is the property "workspace" described in
> http://maven.apache.org/plugins/maven-eclipse-plugin/eclipse-mojo.html#workspace,
> however neither using it as mvn eclipse:eclipse
> -Dworkspace=/home/user/workspace, 
> nor specifying it in the plugin configuration did not give the desired
> results, and the project B is still referenced as a JAR file in the local
> repository.
> 
> Do I miss something?
> 

  Out of curiosity, why don't you use Maven IDe integration, such as
m2eclipse? http://m2eclipse.codehaus.org/

  regards,
  Eugene


-- 
View this message in context: http://www.nabble.com/eclipse-plugin%2C-resolve-dependencies-to-the-projects-in-the-workspace-tp19610981p19616050.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: eclipse plugin, resolve dependencies to the projects in the workspace

Posted by Eugeny N Dzhurinsky <bo...@redwerk.com>.
On Mon, Oct 06, 2008 at 04:51:55PM +0300, Eugeny N Dzhurinsky wrote:
> On Tue, Sep 23, 2008 at 06:16:20AM +0930, Barrie Treloar wrote:
> > yes, from the command line you use "Expression" not the configuration
> > valeue, so use "eclipse.workspace"
> > as in
> > 
> > mvn eclipse:eclipse -Declipse.workspace=/home/user/workspace
> 
> This doesn't work either - a JAR dependency is being added instead of the
> project. Is there any way to see what is wrong?

Sorry, my bad. I've got the source for maven eclipse plugin and realized if I
specify the workspace path as ~/workspace - it doesn't find any files there.
I wrote the test case for Java and found the listFiles method returns null if
the directory is specified with ~ in front instead of the full path. Awesome )

-- 
Eugene N Dzhurinsky

Re: eclipse plugin, resolve dependencies to the projects in the workspace

Posted by Eugeny N Dzhurinsky <bo...@redwerk.com>.
On Tue, Sep 23, 2008 at 06:16:20AM +0930, Barrie Treloar wrote:
> yes, from the command line you use "Expression" not the configuration
> valeue, so use "eclipse.workspace"
> as in
> 
> mvn eclipse:eclipse -Declipse.workspace=/home/user/workspace

This doesn't work either - a JAR dependency is being added instead of the
project. Is there any way to see what is wrong?

Thank you!

-- 
Eugene N Dzhurinsky

Re: eclipse plugin, resolve dependencies to the projects in the workspace

Posted by Barrie Treloar <ba...@gmail.com>.
On Tue, Sep 23, 2008 at 1:09 AM, Eugeny N Dzhurinsky <bo...@redwerk.com> wrote:
> Hello, everybody!
>
> I have the project A, which depends on the project B, both of the projects are
> located in the same workspace.
>
> When generating the eclipse project files for the project A, the project B
> reference is being taken from the repository as a JAR file.
>
> What I want is to include the project B as a project reference for the project
> A, so when the project A is opened in the Eclipse, the project B is opened as
> well as a dependency, and all changes in the project B are reflected in the
> project A (for example, if some interface contract was changed in the project
> B, the corresponding files in the project A will contain errors, or changes in
> the project A with refactoring will be merged to the project B as well).
>
> I found there is the property "workspace" described in
> http://maven.apache.org/plugins/maven-eclipse-plugin/eclipse-mojo.html#workspace,
> however neither using it as mvn eclipse:eclipse -Dworkspace=/home/user/workspace,
> nor specifying it in the plugin configuration did not give the desired
> results, and the project B is still referenced as a JAR file in the local
> repository.
>
> Do I miss something?
>
> Thank you!
>
> --
> Eugene N Dzhurinsky
>

yes, from the command line you use "Expression" not the configuration
valeue, so use "eclipse.workspace"
as in

mvn eclipse:eclipse -Declipse.workspace=/home/user/workspace

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org