<div dir="ltr"><div dir="ltr"><div dir="ltr"><div>This is great! +1 for adding this to trunk, leaving the when to Dave.</div><div><br></div><div>Two thoughts:</div><div><br></div><div>- Since you've started to "mess" with some #startUp: methods, why not mess with the startUp routine as well? Let's say, you add a flag that lists all items in the startUpList and quits the image. You can then add another flag that lets you choose the position of the DoItFirst class within the list, and insert the class right before processing it (e.g. #processStartUpList:). And by default, the position could be set to some reasonable value (right after SmallInteger, FileStream, et al.). If I don't care about the position, I can just use the default. If I want a special position, I can print the current list and then rerun with an index.</div><div><br></div><div>- I don't know how yet, but it'd be cool to be able to cut off the rest of the startUp list with this utility, or exclude certain classes from the startUp list. In TruffleSqueak, for example, we jump through some hoops to set up an image for headless execution [1] and it'd be nice if we could simplify that with your utility.</div><div><br></div><div>Cheers,</div><div>Fabio</div><div><br></div><div>[1] <a href="https://github.com/hpi-swa/trufflesqueak/blob/4aa371a608bd73e9be1a6c65e727eb45370d23e8/src/de.hpi.swa.trufflesqueak/src/de/hpi/swa/trufflesqueak/image/SqueakImageContext.java#L191-L207">https://github.com/hpi-swa/trufflesqueak/blob/4aa371a608bd73e9be1a6c65e727eb45370d23e8/src/de.hpi.swa.trufflesqueak/src/de/hpi/swa/trufflesqueak/image/SqueakImageContext.java#L191-L207</a></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Nov 26, 2020 at 9:01 PM David T. Lewis <<a href="mailto:lewis@mail.msen.com">lewis@mail.msen.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex">On Sun, Jun 14, 2020 at 01:15:01PM -0400, David T. Lewis wrote:<br>
> A few cups of coffee this morning led to some enhancements to my DoItFirst<br>
> utility, so I decided to put in on SqueakSource.<br>
> <br>
>    <a href="http://www.squeaksource.com/DoItFirst" rel="noreferrer" target="_blank">http://www.squeaksource.com/DoItFirst</a><br>
><br>
<br>
I have been updating this since the original post, and I think it is<br>
in pretty good shape at this point. Latest version on SqueakSource is<br>
DoItFirst-System-Support-dtl.14.mcz.<br>
<br>
In order to make this work properly I also add a couple of references<br>
to DoItFirst from other class startUp methods. That is messy to add to<br>
a MCZ, so I'm attaching a change set containing the latest package plus<br>
the two additional startUp calls.<br>
<br>
I think this is clean enough to consider adding to trunk now, so if<br>
folks think it is a good idea, let me know and I'll add it.<br>
<br>
To summarize (from the -help command line option):<br>
<br>
DoItFirst image arguments:<br>
        -doit argumentlist "evaluate each argument as a doIt expression"<br>
        -evaluate arg "evaluate arg, print result then exit"<br>
        -filein filelist "file in each file named in fileList"<br>
        -cwd path "set FileDirectory defaultDirectory to path prior to evaluating other options"<br>
        -debug "enter a debugger as soon as possible in the startUp processing"<br>
        -help "print this message"<br>
<br>
Dave<br>
<br>
<br>
</blockquote></div></div></div></div>