diff options
author | Amin Bandali <amin@aminb.org> | 2017-02-04 22:16:30 -0500 |
---|---|---|
committer | Amin Bandali <amin@aminb.org> | 2017-02-04 22:23:47 -0500 |
commit | a3aef4fd559160689db31f98df3abfba09342071 (patch) | |
tree | 1fd25d6118ef100e1dfae957c93e3118fdd2e853 /spacemacs/.emacs.d/private | |
parent | fdb1bfc093454352efb4adacfd9eb94ef93460a6 (diff) | |
download | configs-a3aef4fd559160689db31f98df3abfba09342071.tar.gz configs-a3aef4fd559160689db31f98df3abfba09342071.tar.xz configs-a3aef4fd559160689db31f98df3abfba09342071.zip |
Spacemacs erc config updates
Diffstat (limited to '')
-rw-r--r-- | spacemacs/.emacs.d/private/aminb/packages.el | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/spacemacs/.emacs.d/private/aminb/packages.el b/spacemacs/.emacs.d/private/aminb/packages.el index b59d7b5..0ff24e0 100644 --- a/spacemacs/.emacs.d/private/aminb/packages.el +++ b/spacemacs/.emacs.d/private/aminb/packages.el @@ -70,6 +70,38 @@ ;; Restore channel buffers from logs (setq erc-log-insert-log-on-open t) + ;;; (BEGIN) work around log restoration bug + ;; taken from https://www.emacswiki.org/emacs/ErcLogging + + ;; ;;; Original version in the Emacs sources: + ;; (defun erc-log-all-but-server-buffers (buffer) + ;; "Returns t if logging should be enabled in BUFFER. + ;; Returns nil if `erc-server-buffer-p' returns t." + ;; (save-excursion + ;; (save-window-excursion + ;; (set-buffer buffer) + ;; (not (erc-server-buffer-p))))) + + ;; My version: + (defun erc-log-all-but-server-buffers (buffer) + (with-current-buffer buffer + (not (erc-server-buffer-p)))) + ;; + ;; ;;; Anyway, a more direct modification also works fine: + ;; (defun erc-log-all-but-server-buffers (buffer) + ;; (set-buffer buffer) + ;; (not (erc-server-buffer-p))) + ;;; (END) + + (require 'notifications) + (defun erc-global-notify (match-type nick message) + "Notify when a message is recieved." + (notifications-notify + :title nick + :body message + ;; :app-icon (concat spacemacs-assets-directory "spacemacs.svg") + :urgency 'normal)) + (defun vbe:znc-add-server (server port user networks) "Add a server to the list of ZNC servers. We use SSL inconditionaly. Moreover, we don't store the password |