Next: Add Slynk support.

master
Pierre Neidhardt 2020-05-02 18:03:23 +02:00
parent 0b59407a3c
commit 0193442e12
1 changed files with 12 additions and 0 deletions

View File

@ -200,3 +200,15 @@ format."
(define-configuration window
((status-formatter #'my-format-status)))
(load-system :slynk)
(when (find-package :slynk)
(define-command start-slynk (&optional (slynk-port *swank-port*))
"Start a Slynk server that can be connected to, for instance, in
Emacs via SLY.
Warning: This allows Next to be controlled remotely, that is, to
execute arbitrary code with the privileges of the user running Next.
Make sure you understand the security risks associated with this
before running this command."
(slynk:create-server :port slynk-port :dont-close t)
(echo "Slynk server started at port ~a" slynk-port)))