feat(emacs): more cool circe stuff :)

This commit is contained in:
Flinner Yuu 2022-04-10 05:57:53 +03:00
parent 7798ca854f
commit e9797f8242
Signed by: flinner
GPG Key ID: 95CE0DA7F0E58CA6
1 changed files with 29 additions and 18 deletions

View File

@ -467,7 +467,9 @@ Capture
"bl" '(evil-switch-to-windows-last-buffer :which-key "Last Buffer") "bl" '(evil-switch-to-windows-last-buffer :which-key "Last Buffer")
"bi" '(ibuffer :which-key "Ibuffer") "bi" '(ibuffer :which-key "Ibuffer")
"br" '(revert-buffer :which-key "Revert Buffer") "br" '(revert-buffer :which-key "Revert Buffer")
"bb" '(switch-to-buffer :which-key "Switch to buffer") "bb" '(helm-buffers-list :which-key "Switch to buffer")
"bc" '(my/circe/helm-buffers :which-key "Circe Helm")
#+end_src #+end_src
**** Windows (w) **** Windows (w)
@ -848,15 +850,15 @@ better sorting for ivy, company..
(yas-global-mode)) (yas-global-mode))
(use-package yasnippet-snippets (use-package yasnippet-snippets
:defer t
:after yasnippet) :after yasnippet)
#+end_src #+end_src
** Helm ** Helm
dep for =org-books=
#+begin_src emacs-lisp #+begin_src emacs-lisp
(use-package helm :after org-books) (use-package helm
:defer t
:config (helm-autoresize-mode 1))
#+end_src #+end_src
* Org-Mode * Org-Mode
@ -2156,9 +2158,13 @@ I wrote that, neat isn't it? :P
(helm-build-sync-source (buffer-name server-buf) (helm-build-sync-source (buffer-name server-buf)
:candidates :candidates
(cons (cons (buffer-name server-buf) server-buf) (cons (cons (buffer-name server-buf) server-buf)
(cl-loop for buf in (cl-loop for buf in (with-current-buffer server-buf (circe-server-channel-buffers))
(with-current-buffer server-buf (circe-server-channel-buffers)) collect (cons
collect (cons (buffer-name buf) buf))) (let ((buf-name (buffer-name buf)))
(concat buf-name
; add " ***" if buffer has new messagse
(if (member buf-name tracking-buffers) " ***" "")))
buf)))
:action (list (cons "Switch to circe" #'switch-to-buffer)))) :action (list (cons "Switch to circe" #'switch-to-buffer))))
@ -2194,11 +2200,17 @@ I wrote that, neat isn't it? :P
#+begin_src emacs-lisp #+begin_src emacs-lisp
(setq (setq
;; lui-time-stamp-position 'right-margin lui-time-stamp-position 'right-margin
lui-fill-type nil) lui-flyspell-p t
lui-fill-type nil
;Display your own nickname instead of >>> in the channel buffers when you're talking.
circe-format-self-say "<{nick}> {body}"
)
(add-hook 'lui-mode-hook 'my-lui-setup) (add-hook 'lui-mode-hook 'my-lui-setup)
(defun my-lui-setup () (defun my-lui-setup ()
(setf (cdr (assoc 'continuation fringe-indicator-alist)) nil)
(olivetti-mode 1)
(setq (setq
fringes-outside-margins t fringes-outside-margins t
right-margin-width 5 right-margin-width 5
@ -2206,7 +2218,6 @@ I wrote that, neat isn't it? :P
wrap-prefix " ")) wrap-prefix " "))
#+end_src #+end_src
*** znc stuff *** znc stuff
#+begin_src emacs-lisp #+begin_src emacs-lisp
(defun circe-command-ZNC (what) (defun circe-command-ZNC (what)