[Vm-dev] VM Maker: VMMakerUI-eem.59.mcz

commits at source.squeak.org commits at source.squeak.org
Fri Jan 6 21:33:51 UTC 2023


Eliot Miranda uploaded a new version of VMMakerUI to project VM Maker:
http://source.squeak.org/VMMaker/VMMakerUI-eem.59.mcz

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

Name: VMMakerUI-eem.59
Author: eem
Time: 6 January 2023, 1:33:50.018176 pm
UUID: faac0746-9d3a-4c62-b470-d3ef8d2e0adc
Ancestors: VMMakerUI-mt.58

Change the updateVMMaker script so that it updates the current branch, rather than insisting on VMMaker.oscog/update.oscog.  e.g. now it also handles VMMaker.oscog.seperateMarking/update.oscog.seperateMarking

=============== Diff against VMMakerUI-mt.58 ===============

Item was changed:
  ----- Method: TheWorldMainDockingBar>>updateVMMaker (in category '*VMMakerUI-updater') -----
  updateVMMaker
  	<updater: 'Update VMMaker'>
  
+ 	| branch updateMap updater history message |
+ 	branch := (PackageInfo named: #VMMaker) workingCopy currentVersionInfo name.
+ 	updateMap := branch first: (branch indexOf: $- ifAbsent: [branch size + 1]) - 1.
+ 	updateMap := 'update', (updateMap allButFirst: #VMMaker size).
- 	| updater history message |
  	updater := MCMcmUpdater
+ 					updateMapNamed: updateMap
+ 					repository: 'http://source.squeak.org/VMMaker'.
- 		updateMapNamed: 'update.oscog'
- 		repository: 'http://source.squeak.org/VMMaker'.
  	updater lastUpdateMap ifEmpty: [
  		"If this is the first time that you use the updater, start at 5.mcm to avoid loading old code."
  		updater lastUpdateMap at: updater repository put: 5].
  
  	history := updater dependentPackages
  		collect: [:package | package name -> (package workingCopy ancestors
  			"N.B. the first version in a package's history will have empty ancestors."
  			ifEmpty: [nil] ifNotEmpty: [:ancestors| ancestors first])]
  		as: OrderedDictionary.
  
  	updater doUpdate: false.
  	
  	"Set update history to the packages that actually changed."
  	updater dependentPackages do: [:package | | oldVersionInfo newVersionInfo |
  		oldVersionInfo := history at: package name ifAbsent: [].
  		newVersionInfo := package workingCopy ancestors first.
  		(oldVersionInfo ifNil: [0] ifNotNil: [oldVersionInfo versionNumber]) < newVersionInfo versionNumber
  			ifTrue: [history at: package name put: {oldVersionInfo. newVersionInfo}]
  			ifFalse: [history removeKey: package name]].
  	
  	"Prepare message, including the update history and OSVM ci badges."
  	message := String streamContents: [:s |
  		s nextPutAll: 'VMMaker update succesful.<br><br>'.
  		history
  			ifEmpty: [s nextPutAll: 'All packages were already up-to-date.']
  			ifNotEmpty: [s nextPutAll: 'Updated packages:'].
  		history keysAndValuesDo: [:packageName :updateInfo |
  			s nextPutAll: '<br> - '.
  			s nextPutAll: packageName; space.
  			updateInfo isArray
  				ifFalse: [s nextPutAll: '*removed*' translated]
  				ifTrue: [
  					updateInfo first
  						ifNil: [s nextPutAll: '*added*' translated]
  						ifNotNil: [s print: updateInfo first versionNumber].
  					s nextPutAll: ' -> <b>'.
  					s print: updateInfo second versionNumber.
  					s nextPutAll: '</b>']].
  		s nextPutAll: ('<br><br>Url: <a href="{1}">{1}</a>' format: {updater repository}).
  		s nextPutAll: '<br>Map: '; print: updater updateMapName.
  
  		s nextPutAll: '<br>'.
  		#('macOS (x86)' macos
  		'macOS (ARM)' 'macos-arm'
  		'Windows' win
  		'Linux (x86)' linux
  		'Linux (ARM)' 'linux-arm')
  			groupsDo: [:label :workflow |
  				s nextPutAll: ('<br><a href="{2}"><img src="{3}" /> {4}</a> {1}'
  					format: {
  						label.
  						self osvm_GitHubActions_statusPageUrl: workflow.
  						self osvm_GitHubActions_statusBadgeUrl: workflow.
  						self osvm_GitHubActions_statusTimestamp: workflow})].
  		
  		s nextPutAll: ('<br><br>Note that updated platform sources might be available, too: <a href="{1}">{1}</a>' format: {'https://github.com/OpenSmalltalk/opensmalltalk-vm'}).
  			
  			].
  	self inform: message asTextFromHtml.!



More information about the Vm-dev mailing list