You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by KC Baltz <KC...@Copart.Com> on 2005/11/17 01:54:52 UTC

[M2] Eclipse doesn't refresh properly after running mvn as an external command?

I suspect this is a bug in Eclipse, not maven, but I wanted to see if anyone else had experienced it.  
 
I have two projects in Eclipse, and one (project B) depends on the other (project A).  I ran 'mvn eclipse:eclipse' for both and have my classpath set to depend on the M2_REPO.  
 
I tried making a change to project A that should cause project B to no longer compile.  When I ran 'mvn install' via an External Tool launcher in Eclipse, with the "Refresh everything" option turned on, project B did not appear to refresh and still indicated that it compiled.  Hitting F5 on Project B caused it to refresh and indicate the compile error properly.  
 
I've had success with the "Refresh Everything" option and Ant builds before, so I'm somewhat surprised it's not working here.  Can anyone else comment?
 
K.C.

Re: [M2] Eclipse doesn't refresh properly after running mvn as an external command?

Posted by Eric Redmond <er...@gmail.com>.
I wouldn't go so far as to call it a "bug", but it definately an annoyance
:)

It is true that Eclipse does not poll projects to look for changes on the
filesystem unless a particular file is open at the time of change (then
eclipse will pop up a little message telling you something has changed,
asking if you'd like to see the changes). In the case of ant, are you
running ant as an external task, or are you using the ant plugin? If the
latter, I'd assume that the project refresh is just built into the plugin
ala JavaCore. This is certainly something you should mention to Mevenide
when they add 2.0 support.


On 11/16/05, Kenney Westerhof <ke...@apache.org> wrote:
>
> On Wed, 16 Nov 2005, KC Baltz wrote:
>
> This certainly sounds like an eclipse bug. Maybe 'refresh everything'
> just refreshes the project you ran the tool on, not the entire workspace.
>
> Btw, you can run mvn eclipse:eclipse from the parent directory, causing
> project references instead of references to jars to be made. That way
> you immediately see compilation errors in project B when you change
> something in project A (that causes B not to compile, ofcourse ;))
>
> -- Kenney
>
> > I suspect this is a bug in Eclipse, not maven, but I wanted to see if
> anyone else had experienced it.
> >
> > I have two projects in Eclipse, and one (project B) depends on the other
> (project A). I ran 'mvn eclipse:eclipse' for both and have my classpath set
> to depend on the M2_REPO.
> >
> > I tried making a change to project A that should cause project B to no
> longer compile. When I ran 'mvn install' via an External Tool launcher in
> Eclipse, with the "Refresh everything" option turned on, project B did not
> appear to refresh and still indicated that it compiled. Hitting F5 on
> Project B caused it to refresh and indicate the compile error properly.
> >
> > I've had success with the "Refresh Everything" option and Ant builds
> before, so I'm somewhat surprised it's not working here. Can anyone else
> comment?
> >
> > K.C.
> >
>
> --
> Kenney Westerhof
> http://www.neonics.com
> GPG public key: http://www.gods.nl/~forge/kenneyw.key
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

Re: [M2] Eclipse doesn't refresh properly after running mvn as an external command?

Posted by Kenney Westerhof <ke...@apache.org>.
On Wed, 16 Nov 2005, KC Baltz wrote:

This certainly sounds like an eclipse bug. Maybe 'refresh everything'
just refreshes the project you ran the tool on, not the entire workspace.

Btw, you can run mvn eclipse:eclipse from the parent directory, causing
project references instead of references to jars to be made. That way
you immediately see compilation errors in project B when you change
something in project A (that causes B not to compile, ofcourse ;))

-- Kenney

> I suspect this is a bug in Eclipse, not maven, but I wanted to see if anyone else had experienced it.
>
> I have two projects in Eclipse, and one (project B) depends on the other (project A).  I ran 'mvn eclipse:eclipse' for both and have my classpath set to depend on the M2_REPO.
>
> I tried making a change to project A that should cause project B to no longer compile.  When I ran 'mvn install' via an External Tool launcher in Eclipse, with the "Refresh everything" option turned on, project B did not appear to refresh and still indicated that it compiled.  Hitting F5 on Project B caused it to refresh and indicate the compile error properly.
>
> I've had success with the "Refresh Everything" option and Ant builds before, so I'm somewhat surprised it's not working here.  Can anyone else comment?
>
> K.C.
>

--
Kenney Westerhof
http://www.neonics.com
GPG public key: http://www.gods.nl/~forge/kenneyw.key

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