[fluxus] paths ideas and tips [Was: fluxus 0.8 osx default path location]
Artem Baguinski
femistofel at gmail.com
Wed Feb 22 02:17:07 PST 2006
On 22 Feb 2006, at 03:11, mashive .org wrote:
> ive been having a tough time finding its path so i can run the
> scheme scripts, when i do this (load "examples/artic.scm") or this
> (source "examples/artic.scm")
> it does not fly.
> i selected the option "use Current Working directory" which i would
> figure would be in the directory i put fluxus in,
i'm running the latest cvs but the following most probably applies to
0.8 too:
"current working directory" (CWD), when you start fluxus application
bundle (no matter how you start it) will be Fluxus.app/Content/
Resources. I'm not sure why, I'm a total macosx noob.
a work around for now (and a handy thing for later) is to add the
following to your /Users/mashive/.fluxus.scm {assuming your username
is mashive ;-)}:
(chdir "/path/to/working/directory")
you could also change this config for every performance, so that you
keep the scripts made live sorted by performance. you could execute
this command live too, but each time you make fluxus crash you'll
have to reexecute it.
> so naturally i would think those previous examples would work. but
> i havent had any success running any of them. i started to wonder
> whether its because i'm using osx an not linux, but i would find it
> hard to believe the osx version would be broken in that way.
oh i won't be surprised at all if osx was broken in that way ;-)
but lacking osx experience i wonder: why do you expect CWD of an app
bundle to be the directory you put it in? i have all applications in /
Applications and i don't expect them to drop their files there.
Shouldn't default directory be, for example, user's desktop? i
noticed that, for example, all pdfs that i view from web browser
endup on my desktop.
NB: in cvs the "load" was renamed to edit, and i haven't had a look
at the implementation yet. "source" is gone altogether in favor of
standard guile's "load" (yeah, the transition may be confusing, sorry
for having caused that). the following paragraphs below use CVS
terminology.
in addition to "load" guile provides somewhat handier "load-from-
path" which searches all paths in the list "%load-path" (+ it also
tries all extensions from "%load-extensions"). you can configure
these variables in your ~/.fluxus.scm config file, e.g.:
(set! %load-path "." ;; CWD
"/Users/artm/"
"/Users/artm/Desktop"
"/Users/artm/fluxus"
"/usr/local/src/fluxus/examples")
(set! %load-extensions "scm")
{adjust it to your environment of course}
i'd like "edit" function to search these paths as well (using
scm_sys_search_load_path). i'm not sure it cares at the moment, but
i'll fix that.
More information about the Fluxus
mailing list