[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: bug#57955: 29.0.50; Allow session-local ERC modules
From: |
J.P. |
Subject: |
Re: bug#57955: 29.0.50; Allow session-local ERC modules |
Date: |
Thu, 29 Feb 2024 16:25:08 -0800 |
User-agent: |
Gnus/5.13 (Gnus v5.13) |
"J.P." <jp@neverwas.me> writes:
> A new Emacs user recently complained about the lack of an example
> showing local modules being `let'-bound around calls to ERC's entry
> point functions in lisp code. Perhaps we should add such an example to
> the Modules chapter and also possibly update the "Multiple networks"
> example in Advanced > SASL to include a non-SASL connection:
>
> (defun my-erc-up (network)
> (interactive "Snetwork: ")
>
> (pcase network
> ('libera
> (let ((erc-modules (cons 'sasl erc-modules))
> (erc-sasl-mechanism 'external))
> (erc-tls :server "irc.libera.chat" :port 6697
> :client-certificate t)))
> ('example
> (let ((erc-modules (cons 'sasl erc-modules))
> (erc-sasl-auth-source-function
> #'erc-sasl-auth-source-password-as-host))
> (erc-tls :server "irc.example.net" :port 6697
> :user "alyssa"
> :password "Example.Net")))
> (_ (call-interactively #'erc-tls))))
I've added an example similar to this one.