Automatically authenticate with Circe
This commit is contained in:
parent
342bb78246
commit
03baab2134
1 changed files with 13 additions and 1 deletions
|
@ -15,6 +15,7 @@ wanted it. So now I use Circe.
|
||||||
libraries that are used in the configuration of Circe.
|
libraries that are used in the configuration of Circe.
|
||||||
|
|
||||||
#+BEGIN_SRC emacs-lisp
|
#+BEGIN_SRC emacs-lisp
|
||||||
|
(require 'auth-source)
|
||||||
(require 'lui)
|
(require 'lui)
|
||||||
(require 'circe)
|
(require 'circe)
|
||||||
(require 's)
|
(require 's)
|
||||||
|
@ -144,10 +145,21 @@ wanted it. So now I use Circe.
|
||||||
something happens there, though usually not.
|
something happens there, though usually not.
|
||||||
|
|
||||||
#+BEGIN_SRC emacs-lisp
|
#+BEGIN_SRC emacs-lisp
|
||||||
|
(defun oni:circe-nickserv-password (_)
|
||||||
|
(let ((found (nth 0 (auth-source-search :max 1
|
||||||
|
:host "irc.freenode.net"
|
||||||
|
:require '(:secret)))))
|
||||||
|
(when found
|
||||||
|
(let ((secret (plist-get found :secret)))
|
||||||
|
(if (functionp secret)
|
||||||
|
(funcall secret)
|
||||||
|
secret)))))
|
||||||
|
|
||||||
(setq circe-network-options
|
(setq circe-network-options
|
||||||
`(("Freenode"
|
`(("Freenode"
|
||||||
:nick "ryuslash"
|
:nick "ryuslash"
|
||||||
:channels ("#emacs" "#mowedline" "#ninthfloor"))))
|
:channels ("#emacs" "#mowedline" "#ninthfloor")
|
||||||
|
:nickserv-password oni:circe-nickserv-password)))
|
||||||
#+END_SRC
|
#+END_SRC
|
||||||
|
|
||||||
* Change the time-stamp
|
* Change the time-stamp
|
||||||
|
|
Loading…
Reference in a new issue