<div dir="ltr"><div class="gmail_extra">Thanks Colin!<br><br><div class="gmail_quote">On Wed, Jan 15, 2014 at 12:06 PM, Colin Putney <span dir="ltr">&lt;<a href="mailto:colin@wiresong.com" target="_blank">colin@wiresong.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">
<div class="im">On Wed, Jan 15, 2014 at 1:41 PM, Eliot Miranda <span dir="ltr">&lt;<a href="mailto:eliot.miranda@gmail.com" target="_blank">eliot.miranda@gmail.com</a>&gt;</span> wrote:<br>
<div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr"><div><div>I just stumbled across Monticello&#39;s MCPatcher and the Backport button which claims to apply a partial delta to the ancestor of a package.  Does anyone who understands this code know if the code supports loading a package, without installing it, applying a partial set of changes (i.e. the relevant changes form the bootstrap) and saving the package as an mcz?  If it does then I could construct patched versions of the three packages and substitute them in the bootstrap instead of using the hack.</div>

</div></div></blockquote><div><br></div></div><div> Yeah, that ought to work fine. There&#39;s no way to do it through the GUI, but a bit of workspace hackery should do the trick.</div></div></div></div></blockquote><div>
<br></div><div>Here&#39;s a working example that patches a single method:</div><div><br></div><div>| fn fs version method patch ancestry newVersion |</div><div>fn := &#39;/Users/eliot/Glue/repositories/spurnsboot/smalltalk/Kernel.newspeak-bwesterg.682.mcz&#39;.</div>
<div>fs := FileStream readOnlyFileNamed: fn.</div><div>version := [((MCVersionReader readerClassForFileNamed: fn) on: fs fileName: fn) version] ensure: [fs close].</div><div>method := SpurBootstrap class &gt;&gt; #ProtoObjectPROTOTYPEscaledIdentityHash.</div>
<div>patch := MCPatch operations: {MCAddition of: (MCMethodDefinition</div><div><span class="" style="white-space:pre">                                                                                </span>className: #ProtoObject</div><div><span class="" style="white-space:pre">                                                                                </span>classIsMeta: false</div>
<div><span class="" style="white-space:pre">                                                                                </span>selector: #scaledIdentityHash</div><div><span class="" style="white-space:pre">                                                                                </span>category: #comparing</div><div><span class="" style="white-space:pre">                                                                                </span>timeStamp: method timeStamp</div>
<div><span class="" style="white-space:pre">                                                                                </span>source: (method getSourceFromFile asString allButFirst: 20))}.</div><div>ancestry := MCWorkingAncestry new addAncestor: version info.</div><div>newVersion := MCVersion</div>
<div><span class="" style="white-space:pre">                        </span><span style="white-space:pre">        </span>package: version package</div><div><span class="" style="white-space:pre">                                </span>info: (ancestry</div><div><span class="" style="white-space:pre">                                                </span>infoWithName: &#39;Kernel.newspeak.spur-bwesterg.682.mcz&#39;</div>
<div><span class="" style="white-space:pre">                                                </span>message: &#39;Kernel.newspeak-bwesterg.682.mcz patched for Spur&#39;)</div><div><span class="" style="white-space:pre">                                </span>snapshot: (MCPatcher apply: patch to: version snapshot)</div>
<div><span class="" style="white-space:pre">                                </span>dependencies: {}.</div><div>(MCDirectoryRepository new directory: fs directory) storeVersion: newVersion </div></div><div><br></div>-- <br>best,<div>Eliot</div>
</div></div>