From 805b2a8e92ed879aa632e36d9614ed983df3f33c Mon Sep 17 00:00:00 2001 From: Tom Willemse Date: Thu, 3 Sep 2015 15:56:18 +0200 Subject: Stop using ERC, use circe instead --- emacs/.emacs.d/init.el | 38 +++++++++++++++++++++++++------------- 1 file changed, 25 insertions(+), 13 deletions(-) (limited to 'emacs/.emacs.d/init.el') diff --git a/emacs/.emacs.d/init.el b/emacs/.emacs.d/init.el index 4f14092..ef9283d 100644 --- a/emacs/.emacs.d/init.el +++ b/emacs/.emacs.d/init.el @@ -948,6 +948,31 @@ from myaethon2.core.decorators import ( (topmost-intro-cont first c-lineup-topmost-intro-cont c-lineup-gnu-DEFUN-intro-cont)))) +(stante-after circe + (defvar oni:circe-longest-nick 0) + (make-variable-buffer-local 'oni:circe-longest-nick) + + (defun oni:circe-prompt (&rest keywords) + (let* ((nick (plist-get keywords :nick)) + (l (length nick))) + (when (> l oni:circe-longest-nick) + (setq oni:circe-longest-nick l) + (setq-local lui-fill-type (make-string (+ l 3) ?\ ))) + (format "%s %s" (s-pad-left oni:circe-longest-nick " " nick) + (plist-get keywords :body)))) + + (setq circe-format-self-say #'oni:circe-prompt) + (setq circe-format-say #'oni:circe-prompt) + (setq circe-network-options + `(("Freenode" + :nick "ryuslash" + :channels ("#emacs" "#mowedline" "#ninthfloor")))) + (setq lui-time-stamp-position 'right-margin) + (setq lui-time-stamp-format "%H:%M") + (setq lui-fill-type 'variable) + (add-hook 'lui-mode-hook (lambda () (setq right-margin-width 5))) + (add-hook 'circe-channel-mode-hook (lambda () (setq mode-line-format "")))) + (stante-after compile (setq compilation-scroll-output t)) @@ -1010,19 +1035,6 @@ from myaethon2.core.decorators import ( (add-to-list 'emms-player-list 'emms-player-mpd) (setq emms-player-mpd-music-directory "/mnt/music/mp3")) -(stante-after erc - (setq erc-hide-list '("PART")) - (setq erc-nick "ryuslash")) - -(stante-after erc-join - (setq erc-autojoin-channels-alist - '(("freenode.net" "#ninthfloor" "#emacs" "#dispass" "#mowedline")))) - -(stante-after erc-stamp - (setq erc-insert-timestamp-function 'erc-insert-timestamp-left) - (setq erc-timestamp-format "[%H:%M] ") - (setq erc-timestamp-only-if-changed-flag nil)) - (stante-after esh-mode (add-to-list 'eshell-output-filter-functions #'oni:eshell-handle-url) (add-to-list 'eshell-output-filter-functions #'eshell-truncate-buffer)) -- cgit v1.2.3-54-g00ecf