On 06/03/2008, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
> Making install run before eclipse:eclipse is a bad idea in some cases.
> In particular, when a project doesn't compile it is currently possible
> to still run eclipse:eclipse. Making install a pre-requisite would block
> that, which would be really anoying.
>
> I think what the original poster is saying is that
>   eclipse:eclipse
> is correctly generating all of the eclipse projects, but that eclipse
> then displays build errors because the jars that the newly created
> eclipse projects point to don't yet exist. I don't see that as a big
> problem myself. The eclipse projects *do* exist.
>
> And anyway, some very basic user training is all that is needed, to
> ensure that people run
>   mvn install eclipse:eclipse
> rather than
>   mvn eclipse:eclipse
>
> If the users are so dumb that they cannot learn that, then the best
> solution would be to provide an eclipse-setup.bat file for them to click
> on (I assume that category of users run Windows :-)
>
> Perhaps binding eclipse:eclipse to the install phase is also a
> possibility. Then
>   mvn install
> would be all that is needed. It would waste time on every build cycle by
> rewriting bits of the eclipse project def, but it's not a big overhead.


you could always bind it inside a profile, then developers could
use "mvn install -Peclipse" to get IDE files on install (perhaps
they could enable by default in their settings.xml?) while build
machines wouldn't have it enabled - something like...

  <profiles>
    <profile>
      <id>eclipse</id>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-eclipse-plugin</artifactId>
            <version>2.4</version>
            <executions>
              <execution>
                <id>ide-support</id>
                <phase>install</phase>
                <goals>
                  <goal>eclipse</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>

 Note that i haven't tried this; there might be problems I haven't
> thought of..
>
> Regards,
> Simon
>
> [EMAIL PROTECTED] schrieb:
>
> > Hi,
> >
> > This is not possible to configure in your pom file. However, it should
> be possible to adjust the maven Eclipse Plugin to execute the install phase.
> (Just like surefire-reports execute the test phase) For this there should be
> a mojo added to the Maven Eclipse Plugin. This sounds like a nice feature
> request.
> >
> > What do others think of this? That you can execute eclipse:eclipse just
> like normal, but also a goal like eclipse:eclipse-install to execute an
> install before eclipse:eclipse is run?
> >
> > Hth,
> >
> > Nick Stolwijk
> >
> >
> > -----Original Message-----
> > From: 109s [mailto:[EMAIL PROTECTED]
> > Sent: Thu 3/6/2008 10:21
> > To: users@maven.apache.org
> > Subject: Try to run install before eclipse:eclipse
> >
> >
> > Hi,
> >
> > for a multiple project it's necessary to run "mvn install" before "mvn
> > eclipse:eclipse" because of dependencies. I want that install runs
> > automatically if a developer runs eclipse:eclipse but i don't know how i
> can
> > do that. I searched for hours in the internet but i didn't found a
> solution
> > to integrate that into the pom-file. The way to do that with the
> preGoal-Tag
> > is not possible in maven2.
> > I'm very new with maven.
> > I hope somebody can help me.
> >
> > Greetings
> > Andi
> >
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


-- 
Cheers, Stuart

Reply via email to