Skip to content

Commit 3533e69

Browse files
committed
Add variable for accept-process-output, increase default timeout
1 parent 5253533 commit 3533e69

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

hy-shell.el

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,13 @@
5151
(defvar hy-shell--redirect-timeout 0.5
5252
"Seconds (float) to allow redirection commands to complete before quitting.")
5353

54+
(defvar hy-shell--startup-timeout 3
55+
"Seconds (float) for `accept-process-output' to wait for REPL banner text.
56+
57+
`hy-shell--redirect-check-prompt-regexp' may throw an error if
58+
`accept-process-output' (called in `hy-shell--make-comint') times
59+
out before consuming the REPL banner text.")
60+
5461
;;;; Managed
5562

5663
(defconst hy-shell--name "Hy"
@@ -142,7 +149,7 @@
142149
(inferior-hy-mode))
143150

144151
;; Get shell's initial output/prompt
145-
(accept-process-output (hy-shell--current-process) 0.5)
152+
(accept-process-output (hy-shell--current-process) hy-shell--startup-timeout)
146153

147154
(hy-shell--current-process))))
148155

0 commit comments

Comments
 (0)