[squeak-dev] Installer problem with .mcm files and possible solution

Sebastian Sastre ssastre at seaswork.com
Wed Mar 26 22:37:30 UTC 2008


Hi there,

	I was trying Installer to customize some images I need.

	The .mcm file I needed to load was causing trouble.

	Installer in mcThing makes

	version workingCopy repositoryGroup addRepository: mc

	for every version but if instead of a regular package you asked for a
.mcm then it will give you a DNU on #workingCopy

	So I've patched it unelegantly perhaps to:

	(version isKindOf: MCConfiguration) ifFalse:[
		version workingCopy repositoryGroup addRepository: mc].

	and it worked fine.
	
	cheers

Sebastian Sastre
PD: here is the whole method patched


mcThing

	| files fileToLoad  version  count |

	self logCR: 'finding ', self package asString, '...'.
	"several attempts to read files - repository readableFileNames sometimes
fails"
	count := 0. fileToLoad := nil.
	
	[count := count + 1.
	 (fileToLoad = nil) and:[ count < 5 ] ] 
		whileTrue: [
			files := mc readableFileNames asSortedCollection: self
mcSortFileBlock.
			fileToLoad := files detect: self mcDetectFileBlock
ifNone: [ nil ].
		].

	version := mc versionFromFileNamed: fileToLoad.
	(version isKindOf: MCConfiguration) ifFalse:[
		version workingCopy repositoryGroup addRepository: mc].
	mc creationTemplate: mc asCreationTemplate.
	self log: ' found ', version fileName, '...'.

	^ version




More information about the Squeak-dev mailing list