Results 1 to 8 of 8

Thread: Importing an existing maven project - not a java project

Hybrid View

  1. #1
    Join Date
    Mar 2008
    Posts
    257

    Default Importing an existing maven project - not a java project

    Hello,

    I'm using STS Version: 3.1.0.RELEASE and imported an existing Java Maven project.

    But the project is not seen as a Java project.

    The contextual menu Build Path is empty.

    My project has a pom.xml file and a child module with its own pom.xml file.

    It used to be fine on a previous install of Eclipse.

    Before doing the project import, I removed the project files:

    rm -fr .project .settings/

    I don't think I should need to run the command:

    mvn eclipse:eclipse -DdownloadSources,downloadJavadocs

    before doing the project import.

    I wonder what is missing...

    Could it be because I don't have a file called .m2/settings.xml

    Kind Regards,
    Last edited by stephaneeybert; Nov 10th, 2012 at 09:28 AM.
    Stephane

  2. #2
    Join Date
    Sep 2008
    Location
    Hamburg, Germany
    Posts
    1,638

    Default

    Hey Stephane,

    you should be able to import the project using the "Import Existing Maven Project" wizard without running eclipse:eclipse first. The Maven Integration for Eclipse should take care of all that when you use that import wizard. The missing settings.xml should also not be a problem as long as you are not behind a proxy. Otherwise you would need the settings.xml file to configure the proxy settings for Maven.

    When you do the import via the "Import Existing Maven Project...", how does the project look like?

    HTH,
    Martin
    Martin Lippert
    SpringSource, a division of VMware
    SpringSource Tools Team
    http://www.springsource.com
    http://twitter.com/martinlippert

  3. #3
    Join Date
    Mar 2008
    Posts
    257

    Default

    Hi Martin,

    Thanks for the comment. Indeed, that was my understanding too, not needing to run the eclipse:eclipse Maven command.

    I had created the project as you suggest but it still is not a Java project.

    How does it look like ? Well, it's a typical Spring Hibernate DAO layer.

    I took a screenshort too Screenshot - 11112012 - 01:14:20 PM.jpg
    Stephane

  4. #4
    Join Date
    Sep 2008
    Location
    Hamburg, Germany
    Posts
    1,638

    Default

    Hey Stephane!

    Would it be possible to attach the project here to have us take a look? Or are there any steps for me to reproduce this from scratch using a fresh STS 3.1.0 installation?

    -Martin
    Martin Lippert
    SpringSource, a division of VMware
    SpringSource Tools Team
    http://www.springsource.com
    http://twitter.com/martinlippert

  5. #5
    Join Date
    Mar 2008
    Posts
    257

    Default

    Hey Martin,

    It did not happen on the previous versions of Eclipse and STS I used some 6 months ago.

    In fact the same issue happens with all the projects I have. You can try with a simple project of yours and see if you also have the issue.

    Otherwise I'll send you one of my projects.

    Kind Regards,
    Stephane

  6. #6
    Join Date
    Sep 2008
    Location
    Hamburg, Germany
    Posts
    1,638

    Default

    Hey Stepane!

    I did this multiple times in the past (also with the latest STS 3.1.0 version), usually without problems. Therefore I guess we would need to take a look at your specific project... Would that be possible?

    Cheers,
    -Martin
    Martin Lippert
    SpringSource, a division of VMware
    SpringSource Tools Team
    http://www.springsource.com
    http://twitter.com/martinlippert

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •