[plt-scheme] Require and a path
>I have expressions like:
>
>(require "string-utils.scm")
>
>Is there a way to use a full or relative path here? I have tried
>(require (build-path 'up "string-utils.scm")) and
>(require (file (build-path 'up "string-utils.scm"))) etc.
>but it all fails with "bad module path ..."
>
>
>Thanks,
>
>Alex
>
The <PLT MzScheme: Language Manual> tells every thing. Since you
asked, I repeat them here. But you should read the document before
asking.
section 5.2
>
>(require require-spec ...)
>
>require-spec is one of
> module-name
> ...
>
section 5.4
>
>module-name is one of
>
>unix-relative-path-string
>(file path-string)
>(lib filename-string collection-string ...)
>(planet . datum)
>path
The (file path-string) is just what you want.
Zhu Chongkai
http://www.neilvandyke.org/mrmathematica/