[squeak-dev] The Trunk: Installer-Core-cmm.381.mcz
commits at source.squeak.org
commits at source.squeak.org
Wed Nov 6 20:32:18 UTC 2013
Chris Muller uploaded a new version of Installer-Core to project The Trunk:
http://source.squeak.org/trunk/Installer-Core-cmm.381.mcz
==================== Summary ====================
Name: Installer-Core-cmm.381
Author: cmm
Time: 30 October 2013, 10:17:57.435 pm
UUID: 1005ce43-3cce-4cf7-ab8c-001c497f17cb
Ancestors: Installer-Core-cmm.380
- Ability to override default repositories when using the new #merge: function.
- #merge: optimization.
=============== Diff against Installer-Core-cmm.380 ===============
Item was changed:
Object subclass: #Installer
instanceVariableNames: 'answers packages messagesToSuppress useFileIn noiseLevel currentRepository'
+ classVariableNames: 'InstallerBindings IsSetToTrapErrors Remembered Repositories SkipLoadingTests ValidationBlock'
- classVariableNames: 'InstallerBindings IsSetToTrapErrors Remembered SkipLoadingTests ValidationBlock'
poolDictionaries: ''
category: 'Installer-Core'!
!Installer commentStamp: 'kph 3/30/2009 01:29' prior: 0!
Documentation now available at http://installer.pbwiki.com/Installer
useFileIn - flag to load source.st rather than using Monticello!
Item was added:
+ ----- Method: Installer class>>airplaneMode (in category 'repository-overrides') -----
+ airplaneMode
+ "Override all remote repositories with the package cache."
+ self overrideRemoteRepostoriesWith: MCCacheRepository default!
Item was added:
+ ----- Method: Installer class>>clearOverrides (in category 'repository-overrides') -----
+ clearOverrides
+ "Remove all repository overrides and load everthing from the specified default repositories when using #merge:."
+ Repositories := Dictionary new!
Item was added:
+ ----- Method: Installer class>>defaultRepositoryFor: (in category 'private') -----
+ defaultRepositoryFor: anAssociation
+ "private -- answer the MC repository specified by anAssociation."
+ ^ (self perform: anAssociation key)
+ project: anAssociation value ;
+ mc!
Item was changed:
----- Method: Installer class>>doesNotUnderstand: (in category 'custom names') -----
doesNotUnderstand: aMessage
+ self isThisEverCalled: 'What is this?'.
-
^ self remembered at: aMessage selector ifAbsent: [ super doesNotUnderstand: aMessage ]!
Item was added:
+ ----- Method: Installer class>>overrideRemoteRepostoriesWith: (in category 'repository-overrides') -----
+ overrideRemoteRepostoriesWith: aMCRepositoryOrGroup
+ self remoteRepositories do:
+ [ : each | self
+ overrideRepository: each
+ with: aMCRepositoryOrGroup ]!
Item was added:
+ ----- Method: Installer class>>overrideRepository:with: (in category 'repository-overrides') -----
+ overrideRepository: scope with: anMCRepository
+ "When configuring the image with #merge:, override the standard repository specified by scope with anMCRepository."
+ "Installer
+ override: #ss3->'htmlcssparser'
+ with: (MCDirectoryRepository directory: (FileDirectory default / 'mc'))."
+ "Installer
+ override: #ss
+ with: #ssMirror."
+ self repositories
+ at: scope
+ put: anMCRepository!
Item was added:
+ ----- Method: Installer class>>packageCache (in category 'repositories') -----
+ packageCache
+ ^ MCCacheRepository default!
Item was changed:
----- Method: Installer class>>remembered (in category 'custom names') -----
remembered
+ self isThisEverCalled: 'clean the var too.'.
-
^ Remembered ifNil: [ Remembered := IdentityDictionary new ]!
Item was added:
+ ----- Method: Installer class>>remoteRepositories (in category 'repository-overrides') -----
+ remoteRepositories
+ ^ #(#ss #ss3 #cobalt #gemsource #goran #gs #impara #keith #krestianstvo #lukas #saltypickle #sophie #squeak #squeakfoundation #squeaksource #squeaksource3 #ss #ss3 #swa #swasource #wiresong )!
Item was added:
+ ----- Method: Installer class>>removeOverride: (in category 'repository-overrides') -----
+ removeOverride: scope
+ "Remove override specified by scope and return to using the default repository for packages within that scope."
+ ^ self repositories
+ removeKey: scope
+ ifAbsent: [ ]!
Item was changed:
+ ----- Method: Installer class>>repositories (in category 'accessing') -----
- ----- Method: Installer class>>repositories (in category 'instanciation') -----
repositories
+ ^ Repositories ifNil: [ Repositories := Dictionary new ]!
-
- ^ self class organization listAtCategoryNamed: 'repositories'.
- !
Item was added:
+ ----- Method: Installer class>>repositoryFor: (in category 'private') -----
+ repositoryFor: anAssociation
+ "private -- anAssociation key is the repository selector Symbol understood by Intsaller class. It's value is the project name within that HTTP repository."
+ | rep |
+ rep := self repositories
+ at: anAssociation "<-- check for #rep->project overrides first"
+ ifAbsent:
+ [ self repositories
+ at: anAssociation key "<-- override an entire repository."
+ ifAbsent: [ ^ self defaultRepositoryFor: anAssociation ] ].
+ ^ rep isSymbol
+ ifTrue: [ self defaultRepositoryFor: rep -> anAssociation value ]
+ ifFalse: [ rep ]!
Item was added:
+ ----- Method: Installer class>>ssMirror (in category 'repositories') -----
+ ssMirror
+ "The Chilean mirror for the original SqueakSource."
+ ^ self monticello http: 'http://dsal.cl/squeaksource/'!
Item was changed:
----- Method: Installer>>bindingOf: (in category 'script bindings') -----
bindingOf: aString
+ self isThisEverCalled: 'Want to get rid of this and the class-var'.
-
InstallerBindings isNil ifTrue: [ InstallerBindings := Dictionary new].
(InstallerBindings includesKey: aString)
ifFalse: [InstallerBindings at: aString put: nil].
^ InstallerBindings associationAt: aString.!
Item was changed:
----- Method: Installer>>merge: (in category 'public interface') -----
merge: structureOrSymbol
+ | toUncache |
+ toUncache := Set new.
structureOrSymbol isSymbol
ifTrue: [ self merge: (self perform: structureOrSymbol) ]
ifFalse:
[ self
depthFirstOf: structureOrSymbol
do:
[ : each | each isVariableBinding
+ ifTrue:
+ [ currentRepository := self class repositoryFor: each.
+ currentRepository cacheAllFilenames.
+ toUncache add: currentRepository ]
- ifTrue: [ self setRepository: each ]
ifFalse:
[ each isString
ifTrue: [ self primMerge: each ]
+ ifFalse: [ self error: 'invalid specification' ] ] ] ].
+ toUncache do:
+ [ : each | each flushAllFilenames ]!
- ifFalse: [ self error: 'invalid specification' ] ] ] ]!
Item was changed:
----- Method: Installer>>rememberAs: (in category 'custom names') -----
rememberAs: symbol
+ self isThisEverCalled.
-
self class remembered at: symbol asSymbol put: self!
Item was changed:
----- Method: Installer>>setRepository: (in category 'private') -----
+ setRepository: aMCRepository
+ currentRepository := aMCRepository!
- setRepository: anAssociation
- currentRepository := (self class perform: anAssociation key)
- project: anAssociation value ;
- mc!
Item was changed:
----- Method: InstallerMonticello>>project: (in category 'accessing') -----
project: name
project := name.
packages := nil.
(mc respondsTo: #location:) ifTrue:[ mc := mc copy location: root , name ].
+ (mc respondsTo: #directory:) ifTrue: [ mc := mc copy directory: root / name ].
- (mc respondsTo: #directory:) ifTrue: [ mc := mc copy directory: root ,'/', name ].
^self copy.!
More information about the Squeak-dev
mailing list
|