Marco Antoniotti marcoxa@cs.nyu.edu writes:
On Aug 10, 2005, at 3:34 AM, Pascal Bourguignon wrote:
Peter Seibel writes:
FWIW, I put in that feature because I believe in using long, domain qualified package names (a la Java packages) which means that my package names are always prefaced with essentially noise. I'd much rather see:
FOO>
than:
COM.GIGAMONKEYS.FOO>
when *all* my package names start with COM.GIGAMONKEYS. But the flag is there to turn it off if you don't like (which you probably won't if you use short package names that happen to contain a dot.)
The algorithm should check for the presence of several packages with the same last part, and use more parts in these cases.
COM.GIGAMONKEYS.FOO ---> GIGAMONKEYS.FOO COM.INFORMATIMAGO.FOO INFORMATIMAGO.FOO
UK.CO.SMART-SOFT.FOO ---> UK.CO.SMART-SOFT.FOO TW.CO.SMART-SOFT.FOO TW.CO.SMART-SOFT.FOO
Excellent point. I second that.
FWIW, I'd still like a mode where it just shows the last bit (i.e. the current behavior). To me the prompt is just a reminder what package I'm in--it doesn't need to be unambiguous. In practice I'm likely to either be in CL-USER or a package I defined. I don't really care if down in the bowels of some library there's *another* package that happens to have the same last component as mine. But obviously this is based on how I use packages and my preference for a short, clean prompt, even at the cost of some slight ambiguity. So if someone adds this feature, please allow the behavior to continue to be parameterized to support the two current modes (no contracting and contracting to last element) as well as whatever new mode you prefer.
Also, it'd. be nice to either use the shortest nickname
There is some code that tries to fall back on the shortest nickname though I'm not sure how it currently fits relative to the other contracting, mostly because I usually don't use package nicknames.
-Peter