Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [platform-vcm-dev] Patch: default user names for cvs

>>>>> "Kevin" == Kevin McGuire <Kevin_McGuire@xxxxxxx> writes:

Kevin> On a related note, we had at one point "Connect to
Kevin> dev.eclipse.org" as a New Connection menu item, which basically
Kevin> primes all the fields in the connection dialog.

I saw this code in there, commented out.  My other patch obsoletes it
(well, I think so).

Kevin> But I always thought it would be cool to be able to prime the
Kevin> list with 'favorite' places (dev.eclipse.org, source forge,
Kevin> etc).

This is what my larger (unsubmitted) patch does.  Great minds think
alike!

It knows about some standard public repositories: sourceforge.net,
gcc.gnu.org, sources.redhat.com, dev.eclipse.org, subversions.gnu.org,
cvs.gnome.org, and cvs.kde.org.

It knows what anonymous user is used on each repository, and the
correct password.  So if you choose "anonymous" but the repository
wants "anoncvs", it changes it for you.

It knows that for some sites anonymous access must be done via a
different server (this is common practice to reduce bandwidth to the
site developers use).

Instead of specifying the path to the repository, you specify the
project name you care about.  Then it knows how to construct the path.
It also knows that for sourceforge you use cvs.<project>.sourceforge.net.


So, it knows a lot of useful things.  It really makes it easier to
fetch a free software project.

Right now everything is hard-coded.  Even I thought this was ugly :-).

I don't know how to make this easily extensible.

For the mechanics of it, I thought I could just use some kind of
formatting system.  So sourceforge's entry would have
`cvs.{0}.sourceforge.net' for the actual repository name, etc (I can
expand if this is too concise to be understood).  Doing this would let
us move everything to a table-based system (right now it is just a
mass of special-cased code).

For an ordinary unix-y program I would just make a config file
somewhere and that would be that.  For Eclipse, well, I haven't
internalized the style yet.

And also I know I've left some off (there's at least samba, mozilla,
open office, and one more generic one in Sweden whose name I always
forget, plus who knows what in the future).  So clearly some easier
way of doing this would be useful.

Also an organization might consider extending this to include their
own internal cvs servers.  We have 3 or 4 here at Red Hat; it would be
cool if our internal Eclipse magically knew about them...


One last note.  The current implementation of the above adds a `type'
field to ConfigurationWizardMainPage and then puts `if type ==...' in
various methods.  I'm guessing you'd prefer a new subclass instead...?

Tom


Back to the top