[Pkg] The Trunk: Installer-Core-nice.350.mcz
commits at source.squeak.org
commits at source.squeak.org
Mon Jun 27 18:45:01 UTC 2011
Nicolas Cellier uploaded a new version of Installer-Core to project The Trunk:
http://source.squeak.org/trunk/Installer-Core-nice.350.mcz
==================== Summary ====================
Name: Installer-Core-nice.350
Author: nice
Time: 27 June 2011, 8:44:47.278 pm
UUID: 9c24a081-c6be-4425-ab27-1d8664fa16ce
Ancestors: Installer-Core-cmm.349
#anySatisfy: vs #detect:ifNone:
Hint: when you ain't gonna use the element detected by #detect:ifNone:, it probably means you shall better be using one of #(anySatisfy: allStatisfy: noneSatisfy:).
=============== Diff against Installer-Core-cmm.349 ===============
Item was changed:
----- Method: InstallerMonticello>>mcDetectFileBlock: (in category 'monticello') -----
mcDetectFileBlock: pkg
pkg isString ifTrue: [ ^ [ :aFile | aFile beginsWith: pkg ] ].
(pkg isKindOf: Array)
+ ifTrue: [ ^ [ :aFile | pkg anySatisfy: [ :item | aFile beginsWith: item ] ] ].
- ifTrue: [ ^ [ :aFile | (pkg detect: [ :item | aFile beginsWith: item ] ifNone: [ false ]) ~= false ] ].
pkg isBlock ifTrue: [ ^ pkg ].
!
Item was changed:
----- Method: InstallerUniverse>>basicInstall (in category 'basic interface') -----
basicInstall
self packages do: [ :packageName |
| potentials pkg pkgAndVersion version |
pkgAndVersion := self packageAndVersionFrom: packageName.
pkg := pkgAndVersion first.
version := pkgAndVersion last.
potentials := universe packageVersionsForPackage: pkg.
pkg := version isEmpty
ifTrue: [ potentials last ]
ifFalse: [
version := self classUVersion readFrom: version readStream.
+ (potentials anySatisfy: [ :p | p version = version]) ifFalse: [ ^ self error: 'version not found']
- potentials detect:[ :p | p version = version] ifNone: [ ^ self error: 'version not found']
].
universe planToInstallPackage: pkg.
].
self uniDoInstall!
More information about the Packages
mailing list