summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Tom Willemsen2013-03-03 14:47:01 +0100
committerGravatar Tom Willemsen2013-03-03 14:47:01 +0100
commit7856c942888afd7aafdbde09646c59d90cd5fe39 (patch)
treec82f8040e1505138211a9246033adc6f9f3f6eea
parentfea99289b63e1824be7cf7dc0524ebc7dfddf42f (diff)
downloaddotfiles-7856c942888afd7aafdbde09646c59d90cd5fe39.tar.gz
dotfiles-7856c942888afd7aafdbde09646c59d90cd5fe39.zip
emacs: Move (some) jabber config to org
-rw-r--r--emacs/init.el2
-rw-r--r--emacs/init.org32
2 files changed, 32 insertions, 2 deletions
diff --git a/emacs/init.el b/emacs/init.el
index 2856abf..3104840 100644
--- a/emacs/init.el
+++ b/emacs/init.el
@@ -120,7 +120,6 @@
(setq jabber-chat-foreign-prompt-format "%t %u/%r <\n")
(setq jabber-chat-local-prompt-format "%t %u/%r >\n")
(setq jabber-chatstates-confirm nil)
-(setq jabber-history-dir "~/.emacs.d/jabber")
(setq jabber-muc-autojoin '("aethon@muc.ryuslash.org"))
(setq jabber-roster-show-bindings nil)
(setq jabber-vcard-avatars-publish nil)
@@ -175,7 +174,6 @@
(add-hook 'gtags-mode-hook 'oni:gtags-mode-func)
(add-hook 'haskell-mode-hook 'oni:haskell-mode-func)
(add-hook 'html-mode-hook 'oni:html-mode-func)
-(add-hook 'jabber-alert-message-hooks 'oni:jabber-alert-message-func)
(add-hook 'jabber-chat-mode-hook 'oni:jabber-chat-mode-func)
(add-hook 'jabber-roster-mode-hook 'oni:jabber-roster-mode-func)
(add-hook 'java-mode-hook 'oni:java-mode-func)
diff --git a/emacs/init.org b/emacs/init.org
index d8eb2e7..aeb16ca 100644
--- a/emacs/init.org
+++ b/emacs/init.org
@@ -462,3 +462,35 @@
(put 'narrow-to-region 'disabled nil)
(put 'scroll-left 'disabled nil)
#+END_SRC
+
+* jabber
+
+ Require ~jabber-libnotify~ so we can use its alert functions.
+
+ #+BEGIN_SRC emacs-lisp
+ (require 'jabber-libnotify)
+ #+END_SRC
+
+ Enable libnotify alerts for regular and mutli-user chats, this is
+ preferable to seeing them in the echo area.
+
+ #+BEGIN_SRC emacs-lisp
+ (add-hook 'jabber-alert-message-hooks 'jabber-message-libnotify)
+ (add-hook 'jabber-alert-muc-hooks 'jabber-muc-libnotify)
+ #+END_SRC
+
+ Keep track of what was said to and by my contacts, both for
+ "personal" chats and muc chats.
+
+ #+BEGIN_SRC emacs-lisp
+ (setq jabber-history-enabled t
+ jabber-history-muc-enabled t)
+ #+END_SRC
+
+ Store history on a per-contact basis and keep these files in
+ ~$HOME/.emacs.d/jabber-hist~.
+
+ #+BEGIN_SRC emacs-lisp
+ (setq jabber-use-global-history nil
+ jabber-history-dir "~/.emacs.d/jabber-hist")
+ #+END_SRC