2 Replies Latest reply on Oct 18, 2013 9:22 PM by tm2

    Eclipse integration with newer Forge versions?

    tm2 Newbie

      [Meta:  if the answer to this is "RTFM", where is it that I should have looked?]

       

      I'm a quiche-eating IDE user, so I'm running Forge in JBoss Tools 4.1 (on Eclipse 4.3.1), not standalone.

       

      If I use the Forge version (1.3.3) that was bundled with JBoss Tools, all is good:  Forge "new-project" automagically generates the appropriate Eclipse artifacts (.classpath and .project), and Eclipse recognizes and displays the project.

       

      I downloaded and unzipped Forge 1.4.2 and, in Eclipse Window -> Preferences, used Forge -> Installed Forge Runtimes to add the unpacked Forge 1.4.2 runtime and mark it as the default runtime to use.

       

      With that setup, Forge 1.4.2 starts up fine in Eclipse and "new-project" generates a new Maven project.  But it doesn't have any Eclipse artifacts, so not surprisingly the project is invisible to Eclipse.

       

      Probably the missing automagic is something really simple (at a guess, perhaps the embedded 1.3.3 knows it should run "mvn eclipse:eclipse" and does that, whereas perhaps my unpacked 1.4.2 doesn't get the message to do that?), but:

      1. Is there something I should have configured somewhere so that the Eclipse-artifact automagic "just works" for e.g. my unpacked Forge 1.4.2 runtime, or
      2. If #1 is a non-starter, should I just remember to intone something (e.g. "mvn eclipse:eclipse"?) after "new-project", or is there more to it than that?

       

      Just for grins I tried "mvn eclipse:eclipse", which did indeed generate .classpath, .project etc but still didn't make the project visible to Eclipse (even after an Eclipse restart), so presumably there's something else needed, maybe in the .metadata for the Eclipse workspace?

        • 1. Re: [forge-users] Eclipse integration with newer Forge versions?
          Lincoln Baxter III Master

          Hmm, that does seem like an integration problem. My recommendation would be

          against using mvn eclipse:eclipse, but rather "File --> Import --> Existing

          Maven Project"

           

          If that option is not available, that is likely also the reason why the

          import did not work in the first place. I hope this helps! Let us know if

          it works

           

           

          On Fri, Oct 18, 2013 at 3:24 PM, <forge-users@lists.jboss.org> wrote:

           

          [Meta:  if the answer to this is "RTFM", where is it that I should have

          looked?]

           

          I'm a quiche-eating IDE user, so I'm running Forge in JBoss Tools 4.1 (on

          Eclipse 4.3.1), not standalone.

           

          If I use the Forge version (1.3.3) that was bundled with JBoss Tools, all

          is good:  Forge "new-project" automagically generates the appropriate

          Eclipse artifacts (.classpath and .project), and Eclipse recognizes and

          displays the project.

           

          I downloaded and unzipped Forge 1.4.2 and, in Eclipse Window ->

          Preferences, used Forge -> Installed Forge Runtimes to add the unpacked

          Forge 1.4.2 runtime and mark it as the default runtime to use.

           

          With that setup, Forge 1.4.2 starts up fine in Eclipse and "new-project"

          generates a new Maven project.  But it doesn't have any Eclipse artifacts,

          so not surprisingly the project is invisible to Eclipse.

           

          Probably the missing automagic is something really simple (at a guess,

          perhaps the embedded 1.3.3 knows it should run "mvn eclipse:eclipse" and

          does that, whereas perhaps my unpacked 1.4.2 doesn't get the message to do

          that?), but:

          1. Is there something I should have configured somewhere so that the

          Eclipse-artifact automagic "just works" for e.g. my unpacked Forge 1.4.2

          runtime, or

          2. If #1 is a non-starter, should I just remember to intone something

          (e.g. "mvn eclipse:eclipse"?) after "new-project", or is there more to it

          than that?

           

          Just for grins I tried "mvn eclipse:eclipse", which did indeed generate

          .classpath, .project etc but still didn't make the project visible to

          Eclipse (even after an Eclipse restart), so presumably there's something

          else needed, maybe in the .metadata for the Eclipse workspace?

           

          Posted by forums

          Original post: https://community.jboss.org/message/842366#842366

           

          _______________________________________________

          forge-users mailing list

          forge-users@lists.jboss.org

          https://lists.jboss.org/mailman/listinfo/forge-users

           

           

           

           

          --

          Lincoln Baxter, III

          http://ocpsoft.org

          "Simpler is better."

           

          • 2. Re: Eclipse integration with newer Forge versions?
            tm2 Newbie

            Lincoln Baxter III wrote:

             

            Hmm, that does seem like an integration problem. My recommendation would be

            against using mvn eclipse:eclipse, but rather "File --> Import --> Existing

            Maven Project"

             

            Ah, yes -- in other words, do it the m2e way, not the mvn eclipse:eclipse way.

             

            Yes, File --> Import --> Existing Maven Project exists and (now that you have reminded me to use it) seems to work fine.

             

            And, once I did that, there does seem to be some level of integration working between the Forge 1.4.2 shell and Eclipse -- if I use 'cd' in the Forge shell to move around between sibling projects, the Eclipse "Project Explorer" view apparently gets notified and highlights the directory that I have cd'ed to.  I don't have a mental model of how the various moving parts do/don't integrate, but this is working enough that I can keep going.  Thanks.