Hello everyone, I'm currently using Metacello to download my project on a new image very regularly and i'm having some trouble with this message : You are about to load new versions of the following packages that have unsaved changes in the image: System-SessionManager If you continue, you will lose these changes: Load Merge Cancel I searched for something to prevent it but didn't find it, does someone know how I could automaticly do Load in these cases please? Valentin
On Thu, Jun 23, 2016 at 5:25 PM, Valentin Ryckewaert < valentin.ryckewaert@gmail.com> wrote:
Hello everyone,
I'm currently using Metacello to download my project on a new image very regularly and i'm having some trouble with this message :
You are about to load new versions of the following packages that have unsaved changes in the image: System-SessionManager If you continue, you will lose these changes: Load Merge Cancel
I searched for something to prevent it but didn't find it, does someone know how I could automaticly do Load in these cases please?
I don't know the answer to your question, but to find out I would use Tools > Finder > Source to search for "you will lose these changes", put a haltonce in front of it and trace back through the debugger to look for WhatError was raised so that in the playground I could do [ Metacello doStuff ] on: WhatError do: []. Now a random idea, it would be interesting if *all* dialogs raised a notification "Dialog" so you could wrap any expression as... [ Metacello doStuff ] on: Dialog forTextLike: '*you will lose these changes*' answer: #Load. (or a vaguely remember there is something similar already??) cheers -ben
Valentin, For Pharo I use the following pattern to do "automatic loads": [ Metacello new ... load . ] on: Warning, MetacelloSkipDirtyPackageLoad do: [:ex | (ex isKindOf: MetacelloSkipDirtyPackageLoad) ifTrue: [ "Load over dirty packages" ex resume: false ] ifFalse: [ Transcript cr; show: ex description. ex resume: true ] ]. Dale On 6/23/16 2:25 AM, Valentin Ryckewaert wrote:
Hello everyone,
I'm currently using Metacello to download my project on a new image very regularly and i'm having some trouble with this message :
You are about to load new versions of the following packages that have unsaved changes in the image: System-SessionManager If you continue, you will lose these changes: Load Merge Cancel
I searched for something to prevent it but didn't find it, does someone know how I could automaticly do Load in these cases please?
Valentin
participants (3)
-
Ben Coman -
Dale Henrichs -
Valentin Ryckewaert