The Trunk: Monticello-ct.820.mcz

[email protected] Sat, 4 Jul 2026 22:44:10 0000
Newsgroups gmane.comp.lang.smalltalk.squeak.general
Message-ID <[email protected]>
Christoph Thiede uploaded a new version of Monticello to project The Trunk:
http://source.squeak.org/trunk/Monticello-ct.820.mcz

==================== Summary ====================

Name: Monticello-ct.820
Author: ct
Time: 5 July 2026, 12:44:09.515687 am
UUID: 7553b3c9-b025-4261-854d-c1010c38728e
Ancestors: Monticello-mt.818

Fixes multi-environment issues when loading/unloading organization definitions. Normal class/method definitions are already loaded correctly into the current environment.

=============== Diff against Monticello-mt.818 ===============

Item was changed:
  ----- Method: MCOrganizationDefinition>>handlePackageRename:to: (in category 'actions') -----
  handlePackageRename: oldPackageName to: newPackageName 
+ 	| systemOrganization |
+ 	systemOrganization := Environment current organization.
  	categories do:
  		[ : each | (each beginsWith: newPackageName) ifFalse:
  			[ | newCategoryName |
  			newCategoryName := self
  				newCategoryNameFor: each
  				givenRenameFrom: oldPackageName
  				to: newPackageName.
+ 			(systemOrganization categories includes: newCategoryName) ifTrue: [ systemOrganization removeCategory: newCategoryName ].
+ 			systemOrganization
- 			(SystemOrganizer default categories includes: newCategoryName) ifTrue: [ SystemOrganizer default removeCategory: newCategoryName ].
- 			SystemOrganizer default
  				renameCategory: each
  				toBe: newCategoryName ] ]!

Item was changed:
  ----- Method: MCOrganizationDefinition>>postloadOver: (in category 'actions') -----
  postloadOver: oldDefinition
+ 	| systemOrganization |
+ 	systemOrganization := Environment current organization.
+ 	systemOrganization categories:
- 	SystemOrganization categories:
  		(self
+ 			reorderCategories: systemOrganization categories
- 			reorderCategories: SystemOrganization categories
  			original: (oldDefinition ifNil: [#()] ifNotNil: [oldDefinition categories]))!

Item was changed:
  ----- Method: MCOrganizationDefinition>>reorderCategories:original: (in category 'actions') -----
  reorderCategories: allCategories original: oldCategories
  	| first locallyAddedCategories |
  	first := allCategories detect: [:ea | categories includes: ea]
  		ifNone: [^ allCategories, categories].
  	locallyAddedCategories := (oldCategories copyWithoutAll: categories) select: [:cat |
+ 		(Environment current organization listAtCategoryNamed: cat) notEmpty].
- 		(SystemOrganization listAtCategoryNamed: cat) notEmpty].
  	^ 	((allCategories copyUpTo: first) copyWithoutAll: oldCategories, categories),
  		categories,
  		locallyAddedCategories,
  		((allCategories copyAfter: first) copyWithoutAll: oldCategories, categories)
  !

Item was changed:
  ----- Method: MCOrganizationDefinition>>unload (in category 'actions') -----
  unload
+ 	| systemOrganization empty |
+ 	systemOrganization := Environment current organization.
- 	| empty |
  	empty := categories select: [:ea |
+ 		(systemOrganization listAtCategoryNamed: ea) isEmpty].
- 		(SystemOrganization listAtCategoryNamed: ea) isEmpty].
  	SystemOrganization categories:
+ 		(systemOrganization categories copyWithoutAll: empty)!
- 		(SystemOrganization categories copyWithoutAll: empty)!

Squeak-dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]