Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 221727

Summary: Improvements for metadata generated when adding directories and zips
Product: [Eclipse Project] Equinox Reporter: Susan McCourt <susan>
Component: p2Assignee: John Arthorne <john.arthorne>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: pascal, simon_kaegi
Version: 3.4Flags: simon_kaegi: review+
Target Milestone: 3.4 RC1   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
Suggested fix
none
same fix for update sites
none
Improved fix for update sites none

Description Susan McCourt CLA 2008-03-06 15:00:00 EST
Per bug #211679, I'm adding support that lets users add directories and zips as repos, and am auto-generating repos for them.

Some things to consider when generating this information:

- Repo name and description:  right now I am using "User Generated in {path}".  Instead, we may want the name to be the path, and the repo description could say it was user generated at a certain date/time from the source location.

- Should we create a category IU for the groups in the new repo?  The category name  could use the path name or otherwise indicate that these items come from the local drive?  Right now we aren't categorizing the generated groups at all, so they just appear in "Other".  It's not clear that we were successful on generation unless you expand "Other" and see the new content.  Note we could put all generated repos in one category called "User-Generated Features" or something like that, or have a category for each location.

These are pretty straightforward changes, just can't do them until we release the initial support from the branch and can synch up the generation code.
Comment 1 John Arthorne CLA 2008-03-07 17:34:25 EST
"User Generated" doesn't quite have the right feel for me. If I've just downloaded this stuff from some web site, and pointed the "Manage Sites" dialog at the location, as a user it doesn't feel like I've generated anything. I.e., it's an implementation detail that we are doing p2 metadata generation on this stuff. I think I would just use a generic term like "Local site at <blort>". And perhaps have a "Local Sites" category to stash the features in. Although it feels a bit weird that some features will be categorized by site, and others by more meaningful categories, I can't think of a better alternative off-hand.
Comment 2 Susan McCourt CLA 2008-03-13 14:25:35 EDT
Now that generation of repos for directories is handled in the extension location factory, this isn't a UI bug (at least it can't be fixed in the UI).

The generated repo name for directories is now
"Extension: {URL}"

Does the word Extension mean anything?  Per John's suggestion in comment #1, Maybe we should use something like:
"Local Site at {0}"
and it would actually be a little cleaner to show the path as a file system path rather than the URL with the "file:" prefix.

While we are at it, I think the generated repo name for update sites isn't very user friendly either.  It is
"update site: {URL}"

And probably should just be the URL itself, or else the name if the corresponding update site had a name.  I don't think our users should distinguish between old update sites and p2 sites when looking at them in the list.  And if the old site had a description, we should probably set that.

I'm still torn on categories, maybe once we have a presentation that lets you view by repo/category/flat it won't be such a big deal?...perhaps they should all go in the "Other" category and if the user wants to view them by repo they can do so in another view (per bug #216028)
Comment 3 Pascal Rapicault CLA 2008-04-27 20:46:58 EDT
Are we doing anything on this?
Comment 4 Susan McCourt CLA 2008-04-29 12:48:15 EDT
This is a 3.4 polish item and was mentioned again in bug #229364.

I think we should implement my suggestions for generated repository names from comment #2.
Comment 5 John Arthorne CLA 2008-05-06 17:23:23 EDT
Created attachment 98959 [details]
Suggested fix

This implements Susan's suggestion of using the simple file system path if possible.
Comment 6 John Arthorne CLA 2008-05-06 17:23:55 EDT
Simon, can you review.
Comment 7 John Arthorne CLA 2008-05-06 17:39:15 EDT
Created attachment 98965 [details]
same fix for update sites
Comment 8 John Arthorne CLA 2008-05-06 17:40:32 EDT
Created attachment 98967 [details]
Improved fix for update sites

Removed unused NON-NLS comment
Comment 9 Simon Kaegi CLA 2008-05-06 17:47:56 EDT
Looks good for both patches.
Comment 10 John Arthorne CLA 2008-05-06 17:58:37 EDT
Released.