diff options
author | Jose Antonio Ortega Ruiz <jao@gnu.org> | 2009-06-19 20:44:32 +0200 |
---|---|---|
committer | Jose Antonio Ortega Ruiz <jao@gnu.org> | 2009-06-19 20:44:32 +0200 |
commit | ed141a327f13d61f21b4d57bffe4f6c27e5ab93f (patch) | |
tree | 0df6a187e3d9c4145040e5cb13e17b393434978a /elisp | |
parent | b21ba5e786a4ff9a6dc9ccc76e217daf349082d9 (diff) | |
download | geiser-guile-ed141a327f13d61f21b4d57bffe4f6c27e5ab93f.tar.gz geiser-guile-ed141a327f13d61f21b4d57bffe4f6c27e5ab93f.tar.bz2 |
New user command to unregister Scheme implementations.
Diffstat (limited to 'elisp')
-rw-r--r-- | elisp/geiser-impl.el | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/elisp/geiser-impl.el b/elisp/geiser-impl.el index 767a7cf..4239f1e 100644 --- a/elisp/geiser-impl.el +++ b/elisp/geiser-impl.el @@ -68,7 +68,8 @@ determine its scheme flavour." (add-to-list 'geiser-impl--impls impl))) (defun geiser-impl--unregister (impl) - (setq geiser-impl--impls (remove impl geiser-impl--impls))) + (setq geiser-impl--impls (remove impl geiser-impl--impls)) + (ignore-errors (unload-feature (geiser-impl--impl-feature impl)))) (defvar geiser-impl--default-implementation geiser-impl-default-implementation) @@ -240,7 +241,7 @@ implementation to be used by Geiser.")) "Register a new Scheme implementation." (interactive) (let ((current geiser-impl-installed-implementations) - (impl (geiser-impl--read-impl "New implementation: " nil t))) + (impl (geiser-impl--read-impl "New Scheme implementation: " nil t))) (unless (geiser-impl--register impl) (error "geiser-%s.el not found in load-path" impl)) (when (and (not (memq impl current)) @@ -248,6 +249,17 @@ implementation to be used by Geiser.")) (customize-save-variable 'geiser-impl-installed-implementations (cons impl current))))) +(defun geiser-unregister-implementation () + "Unregister an installed Scheme implementation." + (interactive) + (let* ((current geiser-impl-installed-implementations) + (impl (geiser-impl--read-impl "Forget implementation: " current))) + (geiser-impl--unregister impl) + (when (and (impl current) + (y-or-n-p "Forget permanently using customize? ")) + (customize-save-variable + 'geiser-impl-installed-implementations (remove impl current))))) + ;;; Unload support |