diff --git a/src/PharoLauncher-Core/PhLLaunchImageCommand.class.st b/src/PharoLauncher-Core/PhLLaunchImageCommand.class.st index 06110857..c3585eb7 100644 --- a/src/PharoLauncher-Core/PhLLaunchImageCommand.class.st +++ b/src/PharoLauncher-Core/PhLLaunchImageCommand.class.st @@ -129,7 +129,7 @@ PhLLaunchImageCommand >> launchConfigurationOfImage: aPhLImage [ PhLLaunchImageCommand >> launchImage: aPhLImage [ | process launchConfig | - self imagesPresenter ensurePharoVersion. + self imagesPresenter ensurePharoVersionFor: aPhLImage. [ launchConfig := self launchConfigurationOfImage: aPhLImage. launchConfig useSettings: useSettings. process := aPhLImage launchWithConfiguration: launchConfig ] diff --git a/src/PharoLauncher-Spec2/PhLImagesPresenter.class.st b/src/PharoLauncher-Spec2/PhLImagesPresenter.class.st index 20d01a6c..9104badb 100644 --- a/src/PharoLauncher-Spec2/PhLImagesPresenter.class.st +++ b/src/PharoLauncher-Spec2/PhLImagesPresenter.class.st @@ -234,16 +234,14 @@ PhLImagesPresenter >> ensure: aBoolean [ ] { #category : #computing } -PhLImagesPresenter >> ensurePharoVersion [ - | image | - image := self singleImage. - [ image ensurePharoVersion ] +PhLImagesPresenter >> ensurePharoVersionFor: anImage [ + [ anImage ensurePharoVersion ] on: PhLImageVersionFileNotFound do: [ :error | | presenter | presenter := PhLPharoVersionChooserPresenter newApplication: self application. presenter openModal. presenter version ifNil: [ error pass ]. - image versionFile + anImage versionFile writeStreamDo: [ :stream | stream nextPutAll: presenter version ] ] ]