Move Jabber configuration to emacs-config
This commit is contained in:
parent
d4d5e59dfc
commit
b5ade05b79
3 changed files with 0 additions and 126 deletions
|
@ -175,7 +175,6 @@
|
||||||
(with-eval-after-load 'elec-pair (load "oni-elec-pair-init"))
|
(with-eval-after-load 'elec-pair (load "oni-elec-pair-init"))
|
||||||
(with-eval-after-load 'eshell (load "oni-eshell-init"))
|
(with-eval-after-load 'eshell (load "oni-eshell-init"))
|
||||||
(with-eval-after-load 'gnus (load "oni-gnus-init"))
|
(with-eval-after-load 'gnus (load "oni-gnus-init"))
|
||||||
(with-eval-after-load 'jabber (load "oni-jabber-init"))
|
|
||||||
(with-eval-after-load 'js (load "oni-js-mode-init"))
|
(with-eval-after-load 'js (load "oni-js-mode-init"))
|
||||||
(with-eval-after-load 'lui (load "oni-lui-init"))
|
(with-eval-after-load 'lui (load "oni-lui-init"))
|
||||||
(with-eval-after-load 'magit (load "oni-magit-init"))
|
(with-eval-after-load 'magit (load "oni-magit-init"))
|
||||||
|
|
|
@ -1,75 +0,0 @@
|
||||||
;;; oni-jabber-init.el --- Jabber configuration -*- lexical-binding: t; -*-
|
|
||||||
|
|
||||||
;; Copyright (C) 2018 Tom Willemse
|
|
||||||
|
|
||||||
;; Author: Tom Willemse <tom@ryuslash.org>
|
|
||||||
;; Keywords: local
|
|
||||||
|
|
||||||
;; This program is free software; you can redistribute it and/or modify
|
|
||||||
;; it under the terms of the GNU General Public License as published by
|
|
||||||
;; the Free Software Foundation, either version 3 of the License, or
|
|
||||||
;; (at your option) any later version.
|
|
||||||
|
|
||||||
;; This program is distributed in the hope that it will be useful,
|
|
||||||
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
||||||
;; GNU General Public License for more details.
|
|
||||||
|
|
||||||
;; You should have received a copy of the GNU General Public License
|
|
||||||
;; along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
||||||
|
|
||||||
;;; Commentary:
|
|
||||||
|
|
||||||
;; My configuration for jabber.
|
|
||||||
|
|
||||||
;;; Code:
|
|
||||||
|
|
||||||
(require 'jabber)
|
|
||||||
|
|
||||||
(defun oni:set-default-directory ()
|
|
||||||
"Set the default directory to my home directory."
|
|
||||||
(setq default-directory "~/"))
|
|
||||||
|
|
||||||
(setq jabber-account-list
|
|
||||||
`((,(concat "ryuslash@dukgo.com/" (system-name))
|
|
||||||
(:connection-type . starttls))))
|
|
||||||
|
|
||||||
(setq jabber-avatar-cache-directory (oni:data-location "jabber/avatars/")
|
|
||||||
jabber-history-dir (oni:data-location "jabber/hist/"))
|
|
||||||
|
|
||||||
(setq jabber-chat-buffer-format "+%n"
|
|
||||||
jabber-chat-foreign-prompt-format "%t %n "
|
|
||||||
jabber-chat-local-prompt-format "%t %n "
|
|
||||||
jabber-chat-delayed-time-format "%H:%M"
|
|
||||||
jabber-groupchat-buffer-format "++%n"
|
|
||||||
jabber-groupchat-prompt-format "%t %n ")
|
|
||||||
|
|
||||||
(setq jabber-chat-buffer-show-avatar nil
|
|
||||||
jabber-vcard-avatars-publish nil
|
|
||||||
jabber-vcard-avatars-retrieve nil)
|
|
||||||
|
|
||||||
(setq jabber-chat-fill-long-lines nil)
|
|
||||||
|
|
||||||
(setq jabber-chatstates-confirm nil)
|
|
||||||
|
|
||||||
(setq jabber-muc-colorize-local t
|
|
||||||
jabber-muc-colorize-foreign t)
|
|
||||||
|
|
||||||
(setq jabber-history-enabled t
|
|
||||||
jabber-use-global-history nil)
|
|
||||||
|
|
||||||
(setq jabber-roster-show-bindings nil
|
|
||||||
jabber-show-offline-contacts nil)
|
|
||||||
|
|
||||||
(add-hook 'jabber-roster-mode-hook 'oni-jabber-set-roster-mode-line)
|
|
||||||
(add-hook 'jabber-alert-message-hooks 'jabber-message-libnotify)
|
|
||||||
(add-hook 'jabber-alert-muc-hooks 'jabber-muc-libnotify)
|
|
||||||
(add-hook 'jabber-chat-mode-hook 'visual-line-mode)
|
|
||||||
(add-hook 'jabber-alert-presence-hooks 'oni-jabber-show-status-in-buffer)
|
|
||||||
(add-hook 'jabber-chat-mode-hook 'oni:set-default-directory)
|
|
||||||
|
|
||||||
(with-eval-after-load 'jabber-alert
|
|
||||||
(remove-hook 'jabber-alert-presence-hooks 'jabber-presence-echo))
|
|
||||||
|
|
||||||
(provide 'oni-jabber-init)
|
|
||||||
;;; oni-jabber-init.el ends here
|
|
|
@ -1,50 +0,0 @@
|
||||||
;;; oni-jabber.el --- Extra commands and functions for jabber -*- lexical-binding: t; -*-
|
|
||||||
|
|
||||||
;; Copyright (C) 2016 Tom Willemse
|
|
||||||
|
|
||||||
;; Author: Tom Willemse <tom@ryuslash.org>
|
|
||||||
;; Keywords:
|
|
||||||
|
|
||||||
;; This program is free software; you can redistribute it and/or modify
|
|
||||||
;; it under the terms of the GNU General Public License as published by
|
|
||||||
;; the Free Software Foundation, either version 3 of the License, or
|
|
||||||
;; (at your option) any later version.
|
|
||||||
|
|
||||||
;; This program is distributed in the hope that it will be useful,
|
|
||||||
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
||||||
;; GNU General Public License for more details.
|
|
||||||
|
|
||||||
;; You should have received a copy of the GNU General Public License
|
|
||||||
;; along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
||||||
|
|
||||||
;;; Commentary:
|
|
||||||
|
|
||||||
;; Here are some extra commands and functions for jabber.
|
|
||||||
|
|
||||||
;;; Code:
|
|
||||||
|
|
||||||
(require 'jabber-chat)
|
|
||||||
|
|
||||||
;;;###autoload
|
|
||||||
(defun oni-jabber-set-roster-mode-line ()
|
|
||||||
"Change the mode-line to only show the buffer id."
|
|
||||||
(unless (eq major-mode 'jabber-roster-mode)
|
|
||||||
(error "Will not change mode-line, not in the jabber roster buffer"))
|
|
||||||
(setq mode-line-format
|
|
||||||
(list (propertize " %m" 'face 'mode-line-buffer-id))))
|
|
||||||
|
|
||||||
;;;###autoload
|
|
||||||
(defun oni-jabber-show-status-in-buffer
|
|
||||||
(who _oldstatus _newstatus _statustext proposed-alert)
|
|
||||||
"Check to see if WHO has a buffer and if so print their new status.
|
|
||||||
|
|
||||||
Insert PROPOSED-ALERT in the buffer if it is non-nil."
|
|
||||||
(let ((buffer (get-buffer (jabber-chat-get-buffer (symbol-name who)))))
|
|
||||||
(when (and buffer proposed-alert)
|
|
||||||
(with-current-buffer buffer
|
|
||||||
(ewoc-enter-last jabber-chat-ewoc (list :notice proposed-alert
|
|
||||||
:time (current-time)))))))
|
|
||||||
|
|
||||||
(provide 'oni-jabber)
|
|
||||||
;;; oni-jabber.el ends here
|
|
Loading…
Reference in a new issue