Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / Tools / October 2003

Tip: Looking for answers? Try searching our database.

NetBeans 3.5.1 and CVS

Thread view: 
Robert Klemme - 27 Oct 2003 14:55 GMT
Hi folks,

the other day I installed NetBeans and played a bit with it.  Now I would
like to validate my understanding of NetBeans concepts - or learn the
correct version. :-)

I have this in CVS - a scenario which seems quite common to me:

<project root>
 src
   com
     company
       module
         MyClass.java
         TheOtherClass.java
         ...
 lib
   lib1.jar
   lib2.jar
   ...

Now, to use and compile this I have to

1. mount <project root> with relative mount point set to "src" to get the
packages correct.
2. mount <project root> with different (or same?) working dir
3. create links for lib1.jar, etc. in item mounted at 2.
4. add "com" to the project
5. put those locations into the code completion db

Disadvantage of this is that I have to do two CVS updates if I want to
make sure I have the current source and the current libs.  If I mount
<project root> only once, I do either lose access to the libs (with
relative mount point) or I loose the correct package locations of the
sources (with no relative mount point set).

Is this correct?  Is there another, better way to do it?  Thanks in
advance!

Kind regards

   robert
Bryan E. Boone - 28 Oct 2003 02:20 GMT
You're right ....
On the FileSystems tab you can do what you described.  Think of the tab
as "classpath"
on the Project tab, you'll want to "add existing" and point to the "com"
node in the CVS
mount.
If you need to update your lib, go to the FileSystem tab and update.
Otherwise all of your cvs tasks can be completed in the Project tab, since
that's what you've
mounted.

-Bryan

> Hi folks,
>
[quoted text clipped - 38 lines]
>
>     robert
Robert Klemme - 28 Oct 2003 10:23 GMT
> You're right ....
> On the FileSystems tab you can do what you described.  Think of the tab
[quoted text clipped - 6 lines]
> that's what you've
> mounted.

Thanks for clarifying!  Additional questions: is it safe to use the same
local working directory for multiple mounts of the same CVS project?
Especially if I use different, non interfering mount points this should be
ok, I guess.

And: is it recommended to put the relative mount point of the lib mount to
"lib"?  I know there are no Java files to compile, so there's no point in
fixing the package location of them; but with a relative mount point, the
visible and managed portion of the CVS hierarchy is reduced and I won't
accidentally update the whole project tree.

Kind regards

   robert

> -Bryan
>
[quoted text clipped - 40 lines]
> >
> >     robert
Bryan E. Boone - 28 Oct 2003 22:00 GMT
It should be safe for multiple mounts to the same directory.
I do it.  I have 3 mount points.
The parent (where my build.xml lives)
a child (say lib) where my jar files reside (I mount the jars, too)
another child (say src) where com is a directory off that. ( I use com in my
Project tab).

I'm not sure exactly what you meand about the 2nd question...

-Bryan

> > You're right ....
> > On the FileSystems tab you can do what you described.  Think of the tab
[quoted text clipped - 69 lines]
> > >
> > >     robert
Robert Klemme - 29 Oct 2003 09:52 GMT
> It should be safe for multiple mounts to the same directory.
> I do it.  I have 3 mount points.
> The parent (where my build.xml lives)
> a child (say lib) where my jar files reside (I mount the jars, too)
> another child (say src) where com is a directory off that. ( I use com in my
> Project tab).

Thanks for clarifying that!

> I'm not sure exactly what you meand about the 2nd question...

Hm, trying to find better words...  If I mount a CVS repository, NetBeans
shows me the whole hierarchy.  So if I set a relative mount point to "lib"
and the other to "src" then I see only those two sub trees.  Thus I can
update "lib" without worrying about sibling folders (like "src" and
whatever resides at the same level).  I know that normally relative mount
points are used to fix package locations but since there are no .java
files there one could abuse that feature to restrict the visible portion
of the whole project tree.

I have to admit that so far the eclipse approach to version control suits
me much better.  I'm a bit disappointed of NetBeans in this respect,
because mounting a CVS resource and setting the root of the java source
file hierarchy are somewhat intertwined.  IMHO these are two orthogonal
things that shouldn't interfere.

Regards

   robert

> -Bryan
>
[quoted text clipped - 71 lines]
> > > >
> > > >     robert
Bryan E. Boone - 29 Oct 2003 21:46 GMT
That's interesting...
The way Eclipse handles CVS is exactly the reason that I _don't_ use
Eclipse.
NetBeans does nothing "fancy" to it (CVS).  If I checkout, etc with any CVS
client
(and command line) then NetBeans can consume it just fine.  I can even use
the
command line to check out, then mount the CVS directory with NetBeans with
no
problem.

The relative mount points would behave exactly like any CVS checkout.  It
typically
takes a module in CVS and checks it out to any working directory.  The
relative mount
points can be anything.  The package stuff comes into play when you add the
CVS filesystem
to your project tab.

Is this anywhere near to answering your question?

-Bryan

> > It should be safe for multiple mounts to the same directory.
> > I do it.  I have 3 mount points.
[quoted text clipped - 118 lines]
> > > > >
> > > > >     robert
Robert Klemme - 30 Oct 2003 11:51 GMT
> That's interesting...

It really is.

> The way Eclipse handles CVS is exactly the reason that I _don't_ use
> Eclipse.

And you don't miss the synchronize view?  You din't get fooled by the
NetBeans CVS diff utility which seems to be doing nothing, while in fact
opening a window in an unsuspected location without changing focus there?

> NetBeans does nothing "fancy" to it (CVS).  If I checkout, etc with any CVS
> client
[quoted text clipped - 3 lines]
> no
> problem.

I find merging with Eclipse an order of magnitude better than the CVS /
NetBeans way.  Maybe it's ultimately a question of taste...

> The relative mount points would behave exactly like any CVS checkout.

Well not exactly: if I use a relative mount point then an update on the
root node of this mount in the file system view does only update from the
relative mount point downwards.

>  It
> typically
[quoted text clipped - 5 lines]
>
> Is this anywhere near to answering your question?

I'm sorry, no.  AFAICS you rephrased my description but I'm missing the
answer whether using relative mount points to restrict the visible portion
is a good idea. :-}

Nevertheless, thanks for your time!

   robert

> -Bryan
>
[quoted text clipped - 120 lines]
> > > > > >
> > > > > >     robert
Bryan E. Boone - 30 Oct 2003 13:16 GMT
> > That's interesting...
>
[quoted text clipped - 6 lines]
> NetBeans CVS diff utility which seems to be doing nothing, while in fact
> opening a window in an unsuspected location without changing focus there?

Never had that problem.  Diff works just fine.

> > NetBeans does nothing "fancy" to it (CVS).  If I checkout, etc with any
> CVS
[quoted text clipped - 9 lines]
> I find merging with Eclipse an order of magnitude better than the CVS /
> NetBeans way.  Maybe it's ultimately a question of taste...

That would be a question of taste.  Usually merge is just fine.  BUt of
course if there
are incompatible changes, then you have to fix them by hand.

> > The relative mount points would behave exactly like any CVS checkout.
>
> Well not exactly: if I use a relative mount point then an update on the
> root node of this mount in the file system view does only update from the
> relative mount point downwards.

I still say it works the same.

> >  It
> > typically
[quoted text clipped - 12 lines]
>
> Nevertheless, thanks for your time!
I won't turn this into Eclipse vs NetBeans;)  Have fun deciding which one
suits your needs.
-Bryan

>     robert
>
[quoted text clipped - 146 lines]
> > > > > > >
> > > > > > >     robert
Robert Klemme - 31 Oct 2003 09:43 GMT
> > > That's interesting...
> >
[quoted text clipped - 8 lines]
>
> Never had that problem.  Diff works just fine.

The diff is fine, just the UI control seems a bit wired.  But that's
minor.

> > I find merging with Eclipse an order of magnitude better than the CVS /
> > NetBeans way.  Maybe it's ultimately a question of taste...
> >
> That would be a question of taste.  Usually merge is just fine.  BUt of
> course if there
> are incompatible changes, then you have to fix them by hand.

Of course.  But IMHO Eclipse makes this easier and more comfortable.

> > > The relative mount points would behave exactly like any CVS checkout.
> >
[quoted text clipped - 3 lines]
> >
> I still say it works the same.

... on a reduced set of resources.

> I won't turn this into Eclipse vs NetBeans;)

Definititely not.  It's just, I'm a bit dissatisfied since I expected more
of NB and now I'm trying to find out whether it's me or the tool.  At
least I don't seem to be alone with my feelings towards NB, as pointed out
by Matt Stevens in his "10 Things NetBeans Must Do to Survive".

I'll certainly use the NB UI editor when I have to do some UI designing.

>  Have fun deciding which
> one suits your needs.

Yeah.  Thanks for helping to sort that out!

Kind regards

   robert


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.