2012-03-30 16:46, Felipe Torres skrev:
I recently installed sage on a server and it works because when I go to
/usr/local/sage I run ./sage and it runs, but if I want to use it to compile a
sage based file it says:
bash: sage: command not found
[root@localhost sage]$ sage
bash: sage: command not found
[root@localhost sage]$ ./sage
----------------------------------------------------------------------
| Sage Version 4.8, Release Date: 2012-01-20 |
| Type notebook() for the GUI, and license() for information. |
----------------------------------------------------------------------
sage:
Can anyone tell me how can I run sage to compile or run a file, if I need to
configure something or install something else?
Short version:
Try running
export PATH=$PATH:/path/to/your/sage/program
and try again.
Longer version:
Bash does not find the sage executable because it is not in the PATH. By
adding the path to the sage program to your PATH, bash will know how to
find it. In my case sage is in "/home/johan/Applications/":
johan@johan-laptop:~/Applications$ sage
bash: sage: command not found
johan@johan-laptop:~/Applications$ ./sage
----------------------------------------------------------------------
| Sage Version 5.0.beta5, Release Date: 2012-02-22 |
| Type notebook() for the GUI, and license() for information. |
----------------------------------------------------------------------
**********************************************************************
* *
* Warning: this is a prerelease version, and it may be unstable. *
* *
**********************************************************************
sage:
sage:
Exiting Sage (CPU time 0m0.03s, Wall time 0m7.44s).
johan@johan-laptop:~/Applications$ export
PATH=$PATH:/home/johan/Applications
johan@johan-laptop:~/Applications$ sage
----------------------------------------------------------------------
| Sage Version 5.0.beta5, Release Date: 2012-02-22 |
| Type notebook() for the GUI, and license() for information. |
----------------------------------------------------------------------
**********************************************************************
* *
* Warning: this is a prerelease version, and it may be unstable. *
* *
**********************************************************************
sage:
Exiting Sage (CPU time 0m0.03s, Wall time 0m5.17s).
johan@johan-laptop:~/Applications$
Hope it helps.
/ johan
--
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