summaryrefslogtreecommitdiffstats
path: root/emacs/.emacs.d
diff options
context:
space:
mode:
Diffstat (limited to 'emacs/.emacs.d')
-rw-r--r--emacs/.emacs.d/init.el23
1 files changed, 23 insertions, 0 deletions
diff --git a/emacs/.emacs.d/init.el b/emacs/.emacs.d/init.el
index b9b4d36..e10892f 100644
--- a/emacs/.emacs.d/init.el
+++ b/emacs/.emacs.d/init.el
@@ -134,7 +134,14 @@
'(erc-log-insert-log-on-open t)
'(erc-log-mode t)
'(erc-mode-line-format "%t")
+ '(erc-modules
+ (quote
+ (autojoin button completion irccontrols list match menu move-to-prompt netsplit networks noncommands readonly ring stamp track)))
'(erc-prompt ">")
+ '(erc-stamp-mode t)
+ '(erc-timestamp-format "%H:%M ")
+ '(erc-timestamp-only-if-changed-flag t)
+ '(erc-timestamp-use-align-to nil)
'(erc-track-exclude-server-buffer t)
'(erc-track-exclude-types
(quote
@@ -400,6 +407,22 @@
(setq indent-tabs-mode nil)
(setq show-trailing-whitespace)))
+;; IRC
+
+(make-variable-buffer-local
+ (defvar erc-last-datestamp nil))
+
+;; Show minute timestamps on the left and a date header when they change
+(defun ks-timestamp (string)
+ (erc-insert-timestamp-left string)
+ (let ((datestamp (erc-format-timestamp (current-time) erc-datestamp-format)))
+ (unless (string= datestamp erc-last-datestamp)
+ (erc-insert-timestamp-left datestamp)
+ (setq erc-last-datestamp datestamp))))
+
+(setq erc-datestamp-format "[%Y-%m-%d %a]\n"
+ erc-insert-timestamp-function 'ks-timestamp)
+
;; PDF
(defun my-doc-view-hook ()