sage-mode / spkg-install

#!/bin/sh

CUR=`pwd`

# Build and install Python support files
cd src/
python setup.py build

if [ $? -ne 0 ]; then
    echo "Failure to build sage-mode Python support files"
    exit 1
fi

python setup.py install

if [ $? -ne 0 ]; then
    echo "Failure to install sage-mode Python support files"
    exit 1
fi

# Copy emacs lisp to SAGE_DATA, and print helpful instructions
cd "$CUR"
rm -rf $SAGE_DATA/emacs
cp -r emacs $SAGE_DATA/emacs

cat <<EOF


A basic install might include the following Emacs Lisp in your .emacs:

(add-to-list 'load-path (expand-file-name "$SAGE_DATA/emacs"))
(require 'sage "sage")
(setq sage-command "$SAGE_ROOT/sage")

;; If you want sage-view to typeset all your output and have plot()
;; commands inline, uncomment the following line and configure sage-view:
;; (require 'sage-view "sage-view")
;; (add-hook 'sage-startup-hook 'sage-view)
;; You can use commands like
;; (add-hook 'sage-startup-hook 'sage-view
;; 'sage-view-disable-inline-output 'sage-view-disable-inline-plots)
;; to have some combination of features.  In future, the customize interface
;; will make this simpler... hint, hint!


EOF
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.