• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

How to Export Dependencies to Eclipse?

 
Ranch Hand
Posts: 428
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm trying to following the instructions in Massol & O'Brian's "Maven
A developers Notebook" page 20.

I run maven with the default template (plain old console mode java app).

I add a dependency for httpclient as per
http://jakarta.apache.org/commons/httpclient/downloads.html

<dependency>
<id>commons-httpclient</id>
<version>2.0.2</version>
<url>http://jakarta.apache.org/commons/httpclient/</url>;
</dependency>


I run "maven eclipse".


I type maven -Dmaven.eclipse.workspace=c:\documents and
settings\Adminstrator\workspace eclipse:add-maven-repo

I've also tried to configure MAVEN_REPO manually.

I import the project into eclipse.

I still get the red squigglies indicating eclipse does not know how to
resolve the class names.

Can someone tell me why eclipse is not cooperating?.

Thanks,
Siegfried
 
Saloon Keeper
Posts: 27763
196
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
For one thing, don't do "-Dmaven.eclipse.workspace=c:\documents and
settings\Adminstrator\workspace"

Between the backslash and the spaces, the whole command parse becomes questionable.

The #1 best thing to do is not keep your workspace in "Documents and Settings", since that's a really horrible directory name to work with anyway. However, you can escape it. One way is to wrap double-quotes around the whole mess. Another is to find the short name that your system has assigned (e.g.: '-Dmaven.eclipse.workspace=C:\DOCUME~1\Adminstrator\workspace'
reply
    Bookmark Topic Watch Topic
  • New Topic