From d616d21770320149e3784cb493688075786b520b Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Sat, 9 May 2020 11:46:32 +0200 Subject: [PATCH] Next: Load slynk code in external file. --- .config/next/init.lisp | 11 +---------- .config/next/slynk.lisp | 10 ++++++++++ 2 files changed, 11 insertions(+), 10 deletions(-) create mode 100644 .config/next/slynk.lisp diff --git a/.config/next/init.lisp b/.config/next/init.lisp index 5c2a23b4..961cd840 100644 --- a/.config/next/init.lisp +++ b/.config/next/init.lisp @@ -223,16 +223,7 @@ format." (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))) + (next::load-lisp "/home/ambrevar/dotfiles/.config/next/slynk.lisp")) (defvar +dev-data-profile+ (make-instance 'data-profile :name "dev") diff --git a/.config/next/slynk.lisp b/.config/next/slynk.lisp new file mode 100644 index 00000000..bef80199 --- /dev/null +++ b/.config/next/slynk.lisp @@ -0,0 +1,10 @@ +(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))