Skip to main content



      Home
Home » Language IDEs » Java Development Tools (JDT) » How can I quickly add a set of 10 Jar files?
How can I quickly add a set of 10 Jar files? [message #68478] Thu, 26 June 2003 23:01 Go to next message
Eclipse UserFriend
Originally posted by: cay_horstmann.yahoo.com

Hi! I am writing a book on Java Server Faces. I need to design a whole
bunch of fairly simple projects. Each of them needs the same 10 (approx.)
JAR files. I'd like to create a library (similar to the JRE System
Library), add the JAR files to the library, and add the library with a
single command to each new project.

Right now, I go click-click-click-click-click-click-click and wonder
whether it's time to back to Emacs.

I know that I can name a "variable" and then click on "Extend", but it is
still tedious because my JAR files are distributed over multiple
directories.

Thanks for any help,

Cay
Re: How can I quickly add a set of 10 Jar files? [message #68490 is a reply to message #68478] Thu, 26 June 2003 23:25 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: d.wegener(spamblock).attbi.com

You can create a project that contains only the jar files and then make all
the other projects depend on this one.

Create a Java project named Libraries or Dependencies or whatever makes
sense to you. Add all of the jar files to the project as external jars. Go
to the Java Build Path->Exports tab and select all of the jar files. Now go
to the Java Build Path->Projects tab for each of the other projects and
select the library project that you created.


"Cay Horstmann" <cay_horstmann@yahoo.com> wrote in message
news:bdgc30$mjt$1@rogue.oti.com...
> Hi! I am writing a book on Java Server Faces. I need to design a whole
> bunch of fairly simple projects. Each of them needs the same 10 (approx.)
> JAR files. I'd like to create a library (similar to the JRE System
> Library), add the JAR files to the library, and add the library with a
> single command to each new project.
>
> Right now, I go click-click-click-click-click-click-click and wonder
> whether it's time to back to Emacs.
>
> I know that I can name a "variable" and then click on "Extend", but it is
> still tedious because my JAR files are distributed over multiple
> directories.
>
> Thanks for any help,
>
> Cay
>
>
>
Convert simple project to java project? [Re: How can I quickly add a set of 10 Jar files?] [message #68520 is a reply to message #68490] Fri, 27 June 2003 01:23 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: krush_krush.hotmail.com

Ok, that's interesting, I didn't think of that. I had created
a simple project where I put all my jar files, and all
my other projects refer to those.

Now, how do I convert my simple project into a Java project,
without deleting the old project and recreate from scratch
(coz the old one is already in the CVS)?

thanks

kk

On Thu, 26 Jun 2003 22:25:57 -0500, David Wegener wrote:

> You can create a project that contains only the jar files and then make all
> the other projects depend on this one.
>
> Create a Java project named Libraries or Dependencies or whatever makes
> sense to you. Add all of the jar files to the project as external jars. Go
> to the Java Build Path->Exports tab and select all of the jar files. Now go
> to the Java Build Path->Projects tab for each of the other projects and
> select the library project that you created.
>
Re: Convert simple project to java project? [Re: How can I quickly add a set of 10 Jar files?] [message #68565 is a reply to message #68520] Fri, 27 June 2003 04:09 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: daniel.megert.gmx.net

konrad krash wrote:

>Ok, that's interesting, I didn't think of that. I had created
>a simple project where I put all my jar files, and all
>my other projects refer to those.
>
>Now, how do I convert my simple project into a Java project,
>without deleting the old project and recreate from scratch
>(coz the old one is already in the CVS)?
>
Note very obvious but it works:
File > New > Plug-in Development > Convert Projects to Plug-in Projects

Dani
Re: How can I quickly add a set of 10 Jar files? [message #68584 is a reply to message #68478] Fri, 27 June 2003 05:17 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: j.verschoor.nefli.nl

see my post about the library folder classpath container


"Cay Horstmann" <cay_horstmann@yahoo.com> wrote in message
news:bdgc30$mjt$1@rogue.oti.com...
> Hi! I am writing a book on Java Server Faces. I need to design a whole
> bunch of fairly simple projects. Each of them needs the same 10 (approx.)
> JAR files. I'd like to create a library (similar to the JRE System
> Library), add the JAR files to the library, and add the library with a
> single command to each new project.
>
> Right now, I go click-click-click-click-click-click-click and wonder
> whether it's time to back to Emacs.
>
> I know that I can name a "variable" and then click on "Extend", but it is
> still tedious because my JAR files are distributed over multiple
> directories.
>
> Thanks for any help,
>
> Cay
>
>
>
Re: Convert simple project to java project? [Re: How can I quicklyadd a set of 10 Jar files?] [message #68681 is a reply to message #68565] Fri, 27 June 2003 08:22 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: roland.kofler.endlos.at

Daniel Megert wrote:

> konrad krash wrote:

> >Ok, that\'s interesting, I didn\'t think of that. I had created
> >a simple project where I put all my jar files, and all
> >my other projects refer to those.
> >
> >Now, how do I convert my simple project into a Java project,
> >without deleting the old project and recreate from scratch
> >(coz the old one is already in the CVS)?
> >
> Note very obvious but it works:
> File > New > Plug-in Development > Convert Projects to Plug-in Projects
i dont have such an option, may i have to install some plugin first??
Re: Convert simple project to java project? [Re: How can I quicklyadd a set of 10 Jar files?] [message #68709 is a reply to message #68681] Fri, 27 June 2003 08:40 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: daniel.megert.gmx.net

>
>
>>>Ok, that\'s interesting, I didn\'t think of that. I had created
>>>a simple project where I put all my jar files, and all
>>>my other projects refer to those.
>>>
>>>Now, how do I convert my simple project into a Java project,
>>>without deleting the old project and recreate from scratch
>>>(coz the old one is already in the CVS)?
>>>
>>>
>>>
>>Note very obvious but it works:
>>File > New > Plug-in Development > Convert Projects to Plug-in Projects
>>
>>
>i dont have such an option, may i have to install some plugin first??
>
>
I forgot "Project":

File > New > Project > Plug-in Development > Convert Projects to Plug-in Projects

It's in plain 2.1.

Dani
Re: Convert simple project to java project? [message #68729 is a reply to message #68565] Fri, 27 June 2003 09:01 Go to previous messageGo to next message
Eclipse UserFriend
I wouldn't make it a plugin project...

I just added a page for this to my eclipse tips site. See

http://www.javadude.com/eclipse/

and click on Converting a "CVS module into a Java Project"

Hope this helps!

-- Scott

"Daniel Megert" <daniel.megert@gmx.net> wrote in message
news:bdgu36$407$1@rogue.oti.com...
> konrad krash wrote:
>
> >Ok, that's interesting, I didn't think of that. I had created
> >a simple project where I put all my jar files, and all
> >my other projects refer to those.
> >
> >Now, how do I convert my simple project into a Java project,
> >without deleting the old project and recreate from scratch
> >(coz the old one is already in the CVS)?
> >
> Note very obvious but it works:
> File > New > Plug-in Development > Convert Projects to Plug-in Projects
>
> Dani
>
Re: Convert simple project to java project? [message #69010 is a reply to message #68729] Fri, 27 June 2003 11:39 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: burner.zclipse.org

On Fri, 27 Jun 2003 09:01:30 -0400, Scott Stanchfield wrote:

> I wouldn't make it a plugin project...
>
> I just added a page for this to my eclipse tips site. See
>
> http://www.javadude.com/eclipse/
>
> and click on Converting a "CVS module into a Java Project"

I'm curious why you want to check out the project outside of eclipse. I've
taken several CVS modules and made them java projects just fine by doing:

Switch to CVS Repository Exploring Perspective
Browse to the desired CVS module (adding a server if necessary)
Right click on the module
Select "Check out as..."
Java/Java project
Enter the desired name
Click finish
When it says your "project already exists in the workspace, do you want to
overwrite", click OK

Now you've got the java project in your workspace and can customize the
build path as desired.

When you commit the project, make sure to let eclipse add the .project and
..classpath, and you'll be able to simply right click on the module and
"check out as project" next time.

mike


>
> Hope this helps!
>
> -- Scott
>
Re: Convert simple project to java project? [message #69297 is a reply to message #69010] Fri, 27 June 2003 21:40 Go to previous messageGo to next message
Eclipse UserFriend
Cool -- I hadn't noticed that -- is it fairly new?

I'll update the tip at my sight (with credit to you of course)...

Thanks,
-- Scott

"Michael R Head" <burner@zclipse.org> wrote in message
news:pan.2003.06.27.15.39.56.84722@zclipse.org...
> On Fri, 27 Jun 2003 09:01:30 -0400, Scott Stanchfield wrote:
>
> > I wouldn't make it a plugin project...
> >
> > I just added a page for this to my eclipse tips site. See
> >
> > http://www.javadude.com/eclipse/
> >
> > and click on Converting a "CVS module into a Java Project"
>
> I'm curious why you want to check out the project outside of eclipse. I've
> taken several CVS modules and made them java projects just fine by doing:
>
> Switch to CVS Repository Exploring Perspective
> Browse to the desired CVS module (adding a server if necessary)
> Right click on the module
> Select "Check out as..."
> Java/Java project
> Enter the desired name
> Click finish
> When it says your "project already exists in the workspace, do you want to
> overwrite", click OK
>
> Now you've got the java project in your workspace and can customize the
> build path as desired.
>
> When you commit the project, make sure to let eclipse add the .project and
> .classpath, and you'll be able to simply right click on the module and
> "check out as project" next time.
>
> mike
>
>
> >
> > Hope this helps!
> >
> > -- Scott
> >
Re: How can I quickly add a set of 10 Jar files? [message #69335 is a reply to message #68490] Sat, 28 June 2003 00:14 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: cay_horstmann.yahoo.com

Thanks a million. It works like a charm.

Just for the benefit of anyone else wanting to do this...I had to select
the jar file project in two places in the Project->Properties dialog: in
the Java Build Path pane and the Project References pane.

Cay

David Wegener wrote:

> You can create a project that contains only the jar files and then make all
> the other projects depend on this one.

> Create a Java project named Libraries or Dependencies or whatever makes
> sense to you. Add all of the jar files to the project as external jars. Go
> to the Java Build Path->Exports tab and select all of the jar files. Now go
> to the Java Build Path->Projects tab for each of the other projects and
> select the library project that you created.


> \\\"Cay Horstmann\\\" <cay_horstmann@yahoo.com> wrote in message
> news:bdgc30$mjt$1@rogue.oti.com...
> > Hi! I am writing a book on Java Server Faces. I need to design a whole
> > bunch of fairly simple projects. Each of them needs the same 10 (approx.)
> > JAR files. I\\\'d like to create a library (similar to the JRE System
> > Library), add the JAR files to the library, and add the library with a
> > single command to each new project.
> >
> > Right now, I go click-click-click-click-click-click-click and wonder
> > whether it\\\'s time to back to Emacs.
> >
> > I know that I can name a \\\"variable\\\" and then click on
\\\"Extend\\\", but it is
> > still tedious because my JAR files are distributed over multiple
> > directories.
> >
> > Thanks for any help,
> >
> > Cay
> >
> >
> >
Re: Convert simple project to java project? [message #69370 is a reply to message #69297] Sat, 28 June 2003 01:18 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: burner.zclipse.org

On Fri, 27 Jun 2003 21:40:55 -0400, Scott Stanchfield wrote:

> Cool -- I hadn't noticed that -- is it fairly new?

IIRC, I've been doing it since 2.0 (when I first started seriously using
eclipse), but I could be mistaken.


> I'll update the tip at my sight (with credit to you of course)...

Cool, thanks!

mike

>
> Thanks,
> -- Scott
>
Re: Convert simple project to java project? [message #70003 is a reply to message #69010] Mon, 30 June 2003 08:41 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: krush_krush.hotmail.com

Ok, maybe I'm not too smart or something, I can't seem
to get this work as stated. I had to remove the .project
file from cvs first, in order to be able to check out
as a Java project, as Mike said. Now I got my
java project, but I can't export the jar files
as a library like David Wegener stated earlier.

I don't see my jar files in Java Build Path -> Export
tab. All I see is "My-Library/src" with a check box.

Anything wrong with this picture?

thanks

kk

On Fri, 27 Jun 2003 11:39:56 -0400, Michael R Head wrote:

> On Fri, 27 Jun 2003 09:01:30 -0400, Scott Stanchfield wrote:
>
>> I wouldn't make it a plugin project...
>>
>> I just added a page for this to my eclipse tips site. See
>>
>> http://www.javadude.com/eclipse/
>>
>> and click on Converting a "CVS module into a Java Project"
>
> I'm curious why you want to check out the project outside of eclipse. I've
> taken several CVS modules and made them java projects just fine by doing:
>
> Switch to CVS Repository Exploring Perspective
> Browse to the desired CVS module (adding a server if necessary)
> Right click on the module
> Select "Check out as..."
> Java/Java project
> Enter the desired name
> Click finish
> When it says your "project already exists in the workspace, do you want to
> overwrite", click OK
>
> Now you've got the java project in your workspace and can customize the
> build path as desired.
>
> When you commit the project, make sure to let eclipse add the .project and
> .classpath, and you'll be able to simply right click on the module and
> "check out as project" next time.
>
Re: Convert simple project to java project? [message #70376 is a reply to message #70003] Mon, 30 June 2003 12:09 Go to previous message
Eclipse UserFriend
Originally posted by: burner.zclipse.org

On Mon, 30 Jun 2003 20:41:03 +0800, konrad krash wrote:

> Ok, maybe I'm not too smart or something, I can't seem to get this work
> as stated. I had to remove the .project file from cvs first, in order to
> be able to check out as a Java project, as Mike said. Now I got my java
> project, but I can't export the jar files as a library like David
> Wegener stated earlier.
>
> I don't see my jar files in Java Build Path -> Export tab. All I see is
> "My-Library/src" with a check box.


In order for jars and such to show up in the export window, they must
appear in the Libraries tab first. Once you add them there, they should
show up in the "Order and Export" tab.

mike

> Anything wrong with this picture?
>
> thanks
>
> kk
>
Previous Topic:Running PDE JUnit tests from command line (or as external Ant task)
Next Topic:Opening Ant Editor slows everything down
Goto Forum:
  


Current Time: Mon Jul 14 14:52:39 EDT 2025

Powered by FUDForum. Page generated in 0.07292 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top