2

I am using Eclipse Indigo with MercurialEclipse plugin (1.9.1.v201111302231). The workspace contains ~25 java projects.

The problem is that every time I pull new changes I have to:

  1. Uncheck "Project|Build Automatically"
  2. Clean all from "Project|Clean ..."
  3. Refresh all the projects from the project explorer.
  4. Check back "Project|Build Automatically"

Sometimes weird errors pop up when I debug a project and then I have to repeat the same steps. The overall experience is terrible. My question - is this how Eclipse is supposed to work? Can it be the MercurialEclipse plugin, which causes all this? How can I fix it?

I realize that my question probably lacks some information, please tell me what is missing and I will add it.

Thanks.

EDIT

  1. The project sometimes has errors, but only because Eclipse did not automatically refreshed/built the dependency projects. When I manually refresh the dependencies - errors disappear.
  2. Steps 1 and 4 are done out of desperation, because just 2 and 3 sometimes are not enough.
  3. All the projects are normal Java projects.

I am not sure what information to provide on the projects, except just attach their .classpath and .project files. For instance, here they are from just one project:

.classpath:

<?xml version="1.0" encoding="UTF-8"?>
<classpath>
    <classpathentry kind="src" path="src"/>
    <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
    <classpathentry combineaccessrules="false" kind="src" path="/Common"/>
    <classpathentry kind="lib" path="../3rdParty/log4j/1.2.16/log4j-1.2.16.jar"/>
    <classpathentry combineaccessrules="false" kind="src" path="/WebApi"/>
    <classpathentry combineaccessrules="false" kind="src" path="/Core"/>
    <classpathentry kind="lib" path="../3rdParty/restlet-jse/2.0.10/lib/org.restlet.jar" sourcepath="C:/Program Files (x86)/Restlet Framework/Edition Java SE/2.0.10/src"/>
    <classpathentry kind="lib" path="../3rdParty/guice/3.0/aopalliance.jar"/>
    <classpathentry kind="lib" path="../3rdParty/guice/3.0/guice-3.0.jar"/>
    <classpathentry kind="lib" path="../3rdParty/restlet-jse/2.0.10/lib/javax.ws.rs_1.0/javax.ws.rs.jar"/>
    <classpathentry combineaccessrules="false" kind="src" path="/DTOs"/>
    <classpathentry combineaccessrules="false" kind="src" path="/NetworkEditor"/>
    <classpathentry kind="lib" path="../3rdParty/guice/3.0/guice-multibindings-3.0.jar"/>
    <classpathentry combineaccessrules="false" kind="src" path="/Bootstrapper"/>
    <classpathentry kind="lib" path="../3rdParty/guice/3.0/javax.inject.jar"/>
    <classpathentry combineaccessrules="false" kind="src" path="/ShunraLicense"/>
    <classpathentry kind="output" path="bin"/>
</classpath>

.project:

<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
    <name>VCat</name>
    <comment></comment>
    <projects>
    </projects>
    <buildSpec>
        <buildCommand>
            <name>org.eclipse.jdt.core.javabuilder</name>
            <arguments>
            </arguments>
        </buildCommand>
    </buildSpec>
    <natures>
        <nature>org.eclipse.jdt.core.javanature</nature>
    </natures>
</projectDescription>

I will gladly provide more info - just say what.

mark
  • 59,016
  • 79
  • 296
  • 580
  • 1
    steps 1 & 4 are IMHO not needed –  May 17 '12 at 12:48
  • 1
    I doubt this is how it's *supposed* to work. I use Indigo with Subversion, and it's a doddle. – NPE May 17 '12 at 12:48
  • Your build is nto set up correctly, are they web prjects : http://stackoverflow.com/questions/998737/integrating-tomcat-and-eclipse-as-a-hot-deploy-environment – NimChimpsky May 17 '12 at 12:50
  • Since you haven't told us anything about your projects or your build, we can't possibly guess what's wrong. – bmargulies May 17 '12 at 12:51
  • 25 projects in single workspace? dude create another workspace – Murali Apr 28 '13 at 09:32
  • The dude has already migrated to IntelliJ IDEA and lives happily thereafter. – mark Apr 28 '13 at 13:55
  • 25 projects is not excessive. If, however, resources are constantly out of sync, it could be that the Mercurial plug-in is not updating the files the right way and is causing them to be considered out of sync. Are/were you pulling using something in the UI or from an outside shell or program? – nitind Jul 24 '13 at 23:29
  • I moved to IntelliJ IDEA long since then and forgot about all these issues. – mark Jul 25 '13 at 10:57

1 Answers1

2

Probably you need to clean and build manually because your project is not building automatically as your project probably has errors which keeps it from compiling.

Check the Problems tab.

Alfabravo
  • 7,493
  • 6
  • 46
  • 82
  • even when the project does not have any major problems (mine only has few warnings from a different project, not the one that I want to build) it doesn't get built when I try `Build Project`. I always have to `Project -> Clean -> Clean projects selected below and Start a build immediately` What I am trying to build is a dynamic web project (I am following a tutorial on servlets) with just two servlets. – Rajith Gun Hewage Sep 08 '16 at 11:57