I don't know if this below is a standard way but it works to develop stand 
alone packages:

At sage package directory, for example, 

     /opt/sage-some-version/local/lib/python2.6/site-packages/

execute

    ln -s /home/user1/newpackage/

where newpackage is a directory with all files including all.py.

That  produces the symbolic link:

    /opt/sage/local/lib/python2.6/site-packages/newpackage/

Testing:

    sage: from newpackage.all import *

and it should work.

Now one can change files on
     /home/user1/newpackage/ 
and keep testing without upgrading, etc.

When everything is ready command

   sage -pkg newpackage

produces a "stand alone" package for delivery into other sage system.

Any best way? Please let me know (few months ago I've read the developer 
guide and found nothing special abut this).
Thank you.

Pedro



> Sexta-feira, 30 de Março de 2012 18h14min15s UTC+1, Emil escreveu:
>
> Hi, I'm working on a Sage package. I'm new to Sage, and learning as I
> go along...
>
> My source code is a mixture of .py and .spyx files, that (until now) I
> have been attaching() at the sage: prompt. This seems to work quite
> well.
>
> However, I'd like to do things in the "proper" way. So I made a
> directory in SAGE_ROOT/devel/sage/sage/, created __init__.py, all.py,
> and updated the module_list and setup.py files. Then I can build the
> source with sage -b. This works ok as well.
>
> I was wondering, is there a way that I can rebuild the source from the
> sage: prompt, for example using %upgrade? I get the following message
> when I try that:
>
> Delete the following files manually (and rerun %upgrade)
> if you need a full upgrade:
> /Users/ev/.sage/ipython/ipy_user_conf.py
>
> My questions are:
> 1) do people develop sage in this way, or is it more normal to just
> attach() things?
> 2) is it possible to use %upgrade to rebuild by source from the sage: 
> prompt?
>
> Thanks,
>
>
> Emil
>
>

>

-- 
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-support
URL: http://www.sagemath.org

Reply via email to