On Mon, Nov 28, 2016 at 2:13 PM Thierry Goubier <thierry.goub...@gmail.com>
wrote:

> The GitFileTree-MergeDriver is a good place for that since it has a
> Makefile[1] with smalltalk scripting inside ("eval"), and a command line
> handler[2] to handle being used on the command line[3] by git.
>
>
yeah problem is eval works fine for me too.

" I have been doing like this:

#!/bin/bash
./pharo Pharo.image save Builder
./pharo Builder.image LoadBuilder.st --quit

and LoadBuilder.st contains

<code to load configurations and other thing>
Smalltalk saveSession.

Worked for me in a 3.0, so should still be fine.

I could then to a set of images with various names and builders so one
could have all the prerequisites and the last step just loaded my code fast
on my CI."

Yeap that works but I found a nasty bug, pharo has issues when ! is
contained inside a string so this code works

```Smalltalk

Object subclass:#HelloWorld.
HelloWorld class compile:
'run
Transcript show: ''Hello World'' ;cr.
Transcript show: ''Yes we did it again'' ;cr.
^self ' classified: #run.
HelloWorld run.
Smalltalk saveSession.

```

but this code produces an error if contained in a st file

```Smalltalk

Object subclass:#HelloWorld.
HelloWorld class compile:
'run
Transcript show: ''Hello World'' ;cr.
Transcript show: ''Yes we did it again!'' ;cr.
^self ' classified: #run.
HelloWorld run.
Smalltalk saveSession.

```
if the code is passed as eval it works fine. I assume here is because ! is
used to define metadata inside a st file.

Reply via email to