diff options
author | Jose Antonio Ortega Ruiz <jao@gnu.org> | 2012-09-29 23:55:07 +0200 |
---|---|---|
committer | Jose Antonio Ortega Ruiz <jao@gnu.org> | 2012-09-29 23:55:07 +0200 |
commit | b18bd1f1bdfbdd92d3167884676c59b4c27bde92 (patch) | |
tree | 3dc123f91913e1131be1252af7bc2054c93b8286 | |
parent | 566442e67e7e85a5543515278d79e2a464598e0e (diff) | |
download | geiser-guile-b18bd1f1bdfbdd92d3167884676c59b4c27bde92.tar.gz geiser-guile-b18bd1f1bdfbdd92d3167884676c59b4c27bde92.tar.bz2 |
Autoload cookies in geiser.el
Useless there right now, but Emacs package engine is going to use
them.
-rw-r--r-- | elisp/geiser-racket.el | 1 | ||||
-rw-r--r-- | elisp/geiser.el | 31 |
2 files changed, 26 insertions, 6 deletions
diff --git a/elisp/geiser-racket.el b/elisp/geiser-racket.el index 8794f84..9872880 100644 --- a/elisp/geiser-racket.el +++ b/elisp/geiser-racket.el @@ -18,6 +18,7 @@ (require 'geiser-syntax) (require 'geiser-custom) (require 'geiser-base) +(require 'geiser) ;;; Customization: diff --git a/elisp/geiser.el b/elisp/geiser.el index 98ae410..7cf8349 100644 --- a/elisp/geiser.el +++ b/elisp/geiser.el @@ -12,66 +12,83 @@ ;;; Locations: -(defvar geiser-elisp-dir nil +(defconst geiser-elisp-dir (file-name-directory load-file-name) "Directory containing Geiser's Elisp files.") -(defvar geiser-scheme-dir nil +(defconst geiser-scheme-dir (expand-file-name "../scheme/" geiser-elisp-dir) "Directory containing Geiser's Scheme files.") -(setq geiser-elisp-dir (file-name-directory load-file-name)) -(add-to-list 'load-path geiser-elisp-dir) - -(setq geiser-scheme-dir (expand-file-name "../scheme/" geiser-elisp-dir)) +(when (not (member geiser-elisp-dir load-path)) + (add-to-list 'load-path geiser-elisp-dir)) ;;; Autoloads: +;;;###autoload (autoload 'geiser-version "geiser-version" "Echo Geiser's version." t) +;;;###autoload (autoload 'geiser-unload "geiser-reload" "Unload all Geiser code." t) +;;;###autoload (autoload 'geiser-reload "geiser-reload" "Reload Geiser code." t) +;;;###autoload (autoload 'geiser "geiser-repl" "Start a Geiser REPL, or switch to a running one." t) +;;;###autoload (autoload 'run-geiser "geiser-repl" "Start a Geiser REPL." t) +;;;###autoload (autoload 'geiser-connect "geiser-repl" "Start a Geiser REPL connected to a remote server." t) +;;;###autoload (autoload 'switch-to-geiser "geiser-repl" "Switch to a running one Geiser REPL." t) +;;;###autoload (autoload 'run-guile "geiser-guile" "Start a Geiser Guile REPL." t) +;;;###autoload (autoload 'switch-to-guile "geiser-guile" "Start a Geiser Guile REPL, or switch to a running one." t) +;;;###autoload (autoload 'connect-to-guile "geiser-guile" "Connect to a remote Geiser Guile REPL." t) +;;;###autoload (autoload 'run-racket "geiser-racket" "Start a Geiser Racket REPL." t) +;;;###autoload (autoload 'run-gracket "geiser-racket" "Start a Geiser GRacket REPL." t) +;;;###autoload (autoload 'switch-to-racket "geiser-racket" "Start a Geiser Racket REPL, or switch to a running one." t) +;;;###autoload (autoload 'connect-to-racket "geiser-racket" "Connect to a remote Geiser Racket REPL." t) +;;;###autoload (autoload 'geiser-mode "geiser-mode" "Minor mode adding Geiser REPL interaction to Scheme buffers." t) +;;;###autoload (autoload 'turn-on-geiser-mode "geiser-mode" "Enable Geiser's mode (useful in Scheme buffers)." t) +;;;###autoload (autoload 'turn-off-geiser-mode "geiser-mode" "Disable Geiser's mode (useful in Scheme buffers)." t) +;;;###autoload (autoload 'geiser-mode--maybe-activate "geiser-mode") +;;;###autoload (mapc (lambda (group) (custom-add-load group (symbol-name group)) (custom-add-load 'geiser (symbol-name group))) @@ -91,7 +108,9 @@ ;;; Setup: +;;;###autoload (add-hook 'scheme-mode-hook 'geiser-mode--maybe-activate) +;;;###autoload (add-to-list 'auto-mode-alist '("\\.rkt\\'" . scheme-mode)) |