[gambit-list] playing with spheres

Álvaro Castro-Castilla alvaro.castro.castilla at gmail.com
Sat Jan 4 12:16:44 EST 2014


Hi Michael,

Spheres is designed to work as projects with a structure and a config.scm
file. The tasks will handle all that dependencies for you in different
situations.
Using gsi directly is not supported currently. The reason is that you are
not supposed to write ##import code in your source files, but rather use
the config.scm files to define direct dependencies and let the different
tasks to do the work for you. Maybe future releases address that usecase,
for individual source files without config.scm.

If you want to run interpreted code you need to:
"sake host:run"
inside a project.
Otherwise, to compile use:
"sake host:compile"

So, if you want to run code as gsi, just use the "minimal" skeleton and
place the code in the main.scm file.


Cheers!






        Álvaro Castro-Castilla    --    a at fourthbit.com
          Fourthbit: Turning Ideas into Reality.  --  Visit the
Blog<http://blog.fourthbit.com>

 <http://fourthbit.com>



On Fri, Jan 3, 2014 at 3:33 PM, Michael Greenly <
michaelgreenly at logic-refinery.com> wrote:

> I'm very new to gambit and a bit confused by this behavior.  I'm not sure
> if it's a Spheres specific issue or if I'm missing something more obvious.
>  Any help pointing me in the right direction would be greatly appreciated.
>
> I've installed gambit v4.7.1 and Scheme Spheres v0.4 just as the quick
> start guide recommends.
>
> Everything seems to be working, for example I can create a new project
> with 'sfusion new -g minimal foo' and 'sake host:run' works as expected.
>
> What confuses me is that from the repl I can enter '(##import core:
> testing)' and then '(check 42 => 42)' and everything works as expected.
>
> But if I create a file:
>
>     ; test.scm
>     (##import core: testing)
>     (check 42=> 42)
>
> Then run 'gsi test.scm' I get '***ERROR -- Unbound variable: Check'.
>
> I don't understand why there's a difference in behavior between the repl
> and batch mode when using gsi?
>
> --
> Michael Greenly
> http://logic-refinery.com
>
> _______________________________________________
> Gambit-list mailing list
> Gambit-list at iro.umontreal.ca
> https://webmail.iro.umontreal.ca/mailman/listinfo/gambit-list
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.iro.umontreal.ca/pipermail/gambit-list/attachments/20140104/c0f697fe/attachment.htm>


More information about the Gambit-list mailing list