* riece-commands.el (riece-command-save-variables): New command.
authorDaiki Ueno <ueno@unixuser.org>
Wed, 26 Apr 2006 08:31:56 +0000 (08:31 +0000)
committerDaiki Ueno <ueno@unixuser.org>
Wed, 26 Apr 2006 08:31:56 +0000 (08:31 +0000)
lisp/ChangeLog
lisp/riece-addon.el
lisp/riece-commands.el
lisp/riece.el

index 5646dd3..8988f1c 100644 (file)
@@ -1,5 +1,7 @@
 2006-04-26  Daiki Ueno  <ueno@unixuser.org>
 
+       * riece-commands.el (riece-command-save-variables): New command.
+
        * riece-epg.el
        (riece-epg-passphrase-callback-function-for-decrypt): New
        function.
index 74db7d9..95eac5f 100644 (file)
   :type '(repeat (list string))
   :group 'riece-addon-list)
 
+(eval-when-compile
+  (autoload 'riece-command-save-variables "riece-commands"))
+
 (defvar riece-addon-list-mode-map
   (let ((keymap (make-sparse-keymap)))
     (define-key keymap "+" 'riece-command-enable-addon)
     (define-key keymap " " 'scroll-up)
     (define-key keymap [delete] 'scroll-down)
     (define-key keymap "q" 'bury-buffer)
+    (define-key keymap "s" 'riece-command-save-variables)
     keymap))
 
 (defun riece-load-and-build-addon-dependencies (addons)
index f924e51..dcc97b1 100644 (file)
@@ -735,6 +735,15 @@ If prefix argument ARG is non-nil, toggle frozen status."
     (message "")
     (call-interactively command)))
 
+(eval-when-compile
+  (autoload 'riece-save-variables-files "riece"))
+(defun riece-command-save-variables ()
+  "Save `riece-variables-file'."
+  (interactive)
+  (if (or riece-save-variables-are-dirty
+         (y-or-n-p "No changes made.  Save anyway? "))
+      (riece-save-variables-files)))
+
 (provide 'riece-commands)
 
 ;;; riece-commands.el ends here
index 6799912..2fc1393 100644 (file)
@@ -179,6 +179,7 @@ If optional argument SAFE is nil, overwrite previous definitions."
     "p" riece-command-enter-message-to-user
     "q" riece-command-quit
     "r" riece-command-configure-windows
+    "s" riece-command-save-variables
     "x" riece-command-copy-region
     "t" riece-command-topic
     "w" riece-command-who