aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiguel Ángel Moreno <mail@migalmoreno.com>2022-09-20 00:53:59 +0200
committerMiguel Ángel Moreno <mail@migalmoreno.com>2023-03-15 12:19:22 +0100
commit077388ac69b0bc0426444d27155235d4bc2eeaea (patch)
tree1ef5cb54f3b6280acef20beaf9ed26c8eb34a79f
parent7e74c89b9f591fc05b0f304861fada866470c10f (diff)
fix: Fix SLY initialization
-rw-r--r--nyxt.el9
1 files changed, 5 insertions, 4 deletions
diff --git a/nyxt.el b/nyxt.el
index 76d6141..916659e 100644
--- a/nyxt.el
+++ b/nyxt.el
@@ -127,10 +127,11 @@ connect Slynk to it."
((string-match (rx (: (+ any) "Slynk server started at port")) output)
(run-at-time autostart-delay nil
(lambda ()
- (let ((sly-default-connection (nyxt-connect-to-slynk)))
- (nyxt-sly-eval sexps)
- (sleep-for 0.1)
- (nyxt-exwm-focus-window :focus focus)))))
+ (while (not (sly-connected-p))
+ (nyxt-connect-to-slynk)
+ (sleep-for 0.1))
+ (nyxt-sly-eval sexps)
+ (nyxt-exwm-focus-window :focus focus))))
((or (string-match (rx (: (+ any) "Deleting socket")) output)
(/= (process-exit-status process) 0))
(setq nyxt-process nil)))))))