Well those paths look suspicious (probably because you changed them). The paths should be `sage --root` + "/local/share/emacs" and `sage --root` + "/sage" respectively. Really, all I can say is copy what appears in the output of
sage -f https://bitbucket.org/gvol/sage-mode/downloads/sage_mode-0.9.1.spkg Sorry, I'm not more help. Are you using the "app" version? -Ivan On Jun 3, 2013, at 12:12 PM, [email protected] wrote: > ------ > (add-to-list 'load-path "/Applications/sage/to/sage/local/share/emacs") > (require 'sage "sage") > (setq sage-command "/Applications/sage/to/sage/sage") > ------ > > The above is my .emacs file. I changed the path several times but none of > them works. > > On Sunday, June 2, 2013 9:54:27 PM UTC-7, Ivan Andrus wrote: > That sounds like you haven't properly updated the load-path. You can't > simply use > > (add-to-list 'load-path "/path/to/sage/local/share/emacs") > > as I posted (you have to change the path--perhaps you misspelled something?) > but you should be able to copy what is printed in the terminal when > installing sage-mode. If that's what you did, please send your entire .emacs > since there might be some other problem. > > HTH, > Ivan > > On Jun 2, 2013, at 4:43 PM, [email protected] wrote: > >> Hi Ivan, >> This is the error that Emacs reports when I tried to open it. >> ------------- >> File Edit Options Buffers Tools Help >> >> ("emacs" "test.sage") >> Loading encoded-kb...done >> >> >> An error has occurred while loading `/Users/yang/.emacs': >> >> File error: Cannot open load file, sage >> >> To ensure normal operation, you should investigate and remove the >> cause of the error in your initialization file. Start Emacs with >> the `--debug-init' option to view a complete error backtrace. >> >> >> ------------------ >> >> >> On Sunday, June 2, 2013 10:41:16 AM UTC-7, Ivan Andrus wrote: >> Hi Yang, >> >> You install sage-mode like >> >> sage -i https://bitbucket.org/gvol/sage-mode/downloads/sage_mode-0.9.1.spkg >> >> and then follow the instructions printed, namely adding something like >> >> (add-to-list 'load-path "/path/to/sage/local/share/emacs") >> (require 'sage "sage") >> (setq sage-command "/path/to/sage/sage") >> >> to your .emacs (and then restart Emacs). You _will_ need to create a .emacs >> (or .emacs.d/init.el) for it to work. But if M-x python-mode doesn't work, >> then you might have other problems with your setup. What version of Emacs >> are you using? >> >> -Ivan >> >> On Jun 2, 2013, at 10:48 AM, [email protected] wrote: >> >>> Hi John, that's what I mean. I cannot configure emacs to use sage. What >>> code should I add to my Emacs to make it work? And, in case that I haven't >>> yet create d a .emacs file, should I create one in the home directory? >>> Thanks. >>> >>> On Sunday, June 2, 2013 3:10:34 AM UTC-7, John Cremona wrote: >>> I don't understand what you mean by an editor such as emacs "not >>> working" for Sage code. Sage code is just text, and I have never used >>> anything other than emacs to edit it -- not on a Mac, but why would >>> that make a difference? I have emacs configured to use python-mode, I >>> just have a line in ~/.emacs which tells it to do that for any file >>> with a .sage suffix, though I normally use .py suffix for Sage >>> programming anyway. >>> >>> John Cremona >>> >>> >>> On 2 June 2013 02:15, <[email protected]> wrote: >>> > Hi there, >>> > >>> > I was using Emacs to write codes in other language for a while, but when >>> > I tried to change some sage code using Emacs, it seems not working. I >>> > went to the Sage-Mode page maintained by Ivan Andrus and downloaded >>> > several versions of the SPKG files. However, after opening these files, >>> > Emacs still cannot handle Sage at all. Then I searched for some text >>> > editors, like Komodo, which works perfectly for Python but does not work >>> > for Sage. Now I really need your help. Does anyone know another free text >>> > editor that works for Sage? Much Thanks, Yang. >>> > >>> > -- >>> > You received this message because you are subscribed to the Google Groups >>> > "sage-support" group. >>> > To unsubscribe from this group and stop receiving emails from it, send an >>> > email to [email protected]. >>> > To post to this group, send email to [email protected]. >>> > Visit this group at http://groups.google.com/group/sage-support?hl=en. >>> > For more options, visit https://groups.google.com/groups/opt_out. >>> > >>> > >>> >>> -- >>> You received this message because you are subscribed to the Google Groups >>> "sage-support" group. >>> To unsubscribe from this group and stop receiving emails from it, send an >>> email to [email protected]. >>> To post to this group, send email to [email protected]. >>> Visit this group at http://groups.google.com/group/sage-support?hl=en. >>> For more options, visit https://groups.google.com/groups/opt_out. >>> >>> >> >> >> -- >> You received this message because you are subscribed to the Google Groups >> "sage-support" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected]. >> To post to this group, send email to [email protected]. >> Visit this group at http://groups.google.com/group/sage-support?hl=en. >> For more options, visit https://groups.google.com/groups/opt_out. >> >> > > > -- > You received this message because you are subscribed to the Google Groups > "sage-support" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > Visit this group at http://groups.google.com/group/sage-support?hl=en. > For more options, visit https://groups.google.com/groups/opt_out. > > -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/sage-support?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
