How to work with a remote code synced image


Create the default remote image with:

remote := GtPharoLinkCodeSync default

Before you start it, you should save the image, to ensure the remote image is starting from the same state as the main image.

Start it. This takes a few seconds, as it spawns a new image.

remote start

To stop the remote image later, run:

remote stop

When the remote is running, you can verify in the remote properties view that the changes file is in memory, so changes in the remote will not interfere with the main image. In the playground view you can evaluate an expression and get a proxy object back.

Use cases

Code search

Search remotely by using runRemotely on a filter:

#at:put: gtImplementors runRemotely

Now let's try something fun. First, search for an implementor that does not exist:

#blahblah gtImplementors runRemotely

Then, let's create a method in the local image:

Object compile: 'blahblah ^ 42'

And now let's search remotely again:

#blahblah gtImplementors runRemotely

Running Examples

Run examples remotely by using runRemotely on an example group:

(GtExampleGroup withAll: 'GToolkit-Spotter-Examples' asPackage gtExamplesAllContained) runRemotely

Running Tests

Run tests remotely by using runRemotely on a test suite:

ArrayTest suite gtRunRemotely