Changes between Version 1 and Version 2 of CompareProviders

Show
Ignore:
Author:
james (IP: 65.172.155.230)
Timestamp:
05/21/10 15:19:58 (8 years ago)
Comment:

add note about name length, and pkg comparison

Legend:

Unmodified
Added
Removed
Modified
  • CompareProviders

    v1 v2  
    28288. if, at this point, we have pkgs with an equal score - look at the deplist (one layer deep) and see what they would pull in that is NOT already installed. Add 1 to the score of the pkg with the least new deps to be pulled in. 
    2929 
    30 9. if all else fails and we STILL have  two pkgs with the same score - take the leaders from the list and compare their name length. Subtract the length of the number of character's in the pkgs name from its score
     309. if all else fails and we STILL have  two pkgs with the same score - take the leaders from the list and compare their name length. We add 1,000 and then subtract the length of the number of character's in the pkgs name from its score (the addition of 1000 is to ensure that one of the leaders will be picked)
    3131 
    323210. return the list of providers, sorted best to worst. 
    3333 
     3411. if the packages are the same length, then the packages are compared as shown in "yum list". The one lower in the list will win. 
     35 
     36In all cases we currently just take the winner (first entry) and throw the rest away.