Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [m2e-users] How to correctly get a checked-out project to be a Maven Java project

> -----Original Message-----
> From: m2e-users-bounces@xxxxxxxxxxx [mailto:m2e-users-
> bounces@xxxxxxxxxxx] On Behalf Of Igor Fedorenko
> Sent: Monday, September 10, 2012 2:31 PM
> To: m2e-users@xxxxxxxxxxx
> Subject: Re: [m2e-users] How to correctly get a checked-out project to
> be a Maven Java project
> 
> Does everything work as expected if you checkout the project using
> command line svn client and then import it as existing maven project in
> workspace?

That provided one trivial improvement and added one big defect and a smaller niggle.

It automatically created the same .project file that was created when I made the first project a Maven project.

However, even though I checked out the project from SVN, the imported project lost any knowledge of a mapping to SVN.

Also, importing the project that way didn't let me give the project a different name from its pom artifact name, which I often need.

Otherwise, it still left the project without knowledge of its java sources or dependencies.

> On 12-09-10 5:09 PM, KARR, DAVID wrote:
> > I'm trying to check out a project from our SVN repo that is a
> subfolder of a multi-module project.  A .project file wasn't stored in
> SVN, so when I checked it out, it created a new .project file that is
> almost empty.
> >
> > I need to figure out what correct steps I need to follow to get
> Eclipse to know it's a Maven project with Java source.
> >
> > I first tried the obvious, doing "Convert to Maven project".  That
> changes the .project file to use the Maven2 builder and nature.
> >
> > It still doesn't know I have Java source files, however.
> >
> > I then tried making it a "faceted" project, which allowed me to add
> the Java facet, which added the reference to the existing src/main/java
> and src/test/java trees.
> >
> > At this point, I still had numerous high-level compilation errors.
> Although it was now convinced it was a java project, it now apparently
> didn't know of its maven dependencies.  It didn't even seem like I
> could edit the Build Path to add "Maven Dependencies".  I couldn't
> figure out what "normal" step would work here.  I finally just opened
> up the .classpath file and manually added the incantation that I copied
> from an existing Maven project to define the
> "org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER" entry.
> >
> > That made all the redness go away.
> >
> > Is it supposed to be this hard?
> > _______________________________________________
> > m2e-users mailing list
> > m2e-users@xxxxxxxxxxx
> > https://dev.eclipse.org/mailman/listinfo/m2e-users
> >
> _______________________________________________
> m2e-users mailing list
> m2e-users@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/m2e-users


Back to the top