On 5/25/07, Justin C. Walker <[EMAIL PROTECTED]> wrote:
> Seems to work fine (I retrieved 23:37 version).  One immediate
> comment: it pollutes the console log.  The console log is a good
> debugging aid, but if it's littered with SAGE "GET" logs, it is tough
> to read through and pick out real problems.
>
> Is it easy to provide a log of its own?

Yes.  Any suggestions about which file it should log to?
If you look at
   /Applications/Sage.app/Contents/MacOS/Sage
you'll see the script that is started when you click the icon.
It's this:
-------------------
#!/bin/bash
CUR=`dirname $0`
cd "$CUR"

if [ ! -d "$HOME/.sage" ]; then
    mkdir "$HOME/.sage"
fi

cd "$HOME/.sage"

"$CUR"/sage-2.5.3/sage -notebook  &
-------------------

If the last line were

"$CUR"/sage-2.5.3/sage -notebook > "$HOME/.sage/app.log"

then I think it would log everything to app.log, restarting the log
each time you click the icon.

> > are stored inn the .app.   Perhaps they should be stored in the
> > users home
> > directory under .sage?
>
> Typically, storing "volatile" stuff, or per-user stuff, in the .app
> is A Bad Thing.  There's an "Application Support" directory in each
> user's ~/Library directory that can be used for this purpose.

OK, that's a good idea.  Also, it's where OS X users will naturally look
when they want to find their SAGE notebook, which they might want
to copy to a new machine or backup or something.

> Is it easy to split the active, per-user files by SAGE PID, to avoid
> the problems suggested earlier in this thread?

In the version of the sage app in sageapp.tar.bz2, I modified
sage so the PID stores the port and pid; you're right, storing
the user id as well -- then multiple users can all click the
app icon and get distinct SAGE notebooks.  (How would this
ever happen by the way?)

William

--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/sage-devel
URLs: http://sage.scipy.org/sage/ and http://modular.math.washington.edu/sage/
-~----------~----~----~----~------~----~------~--~---

Reply via email to