On 2/28/2023 11:23 AM, Eli Zaretskii wrote: > How about changing make-frame on master to create a TTY frame in batch > sessions, even if DISPLAY is set in the environment? That could work. Just to see what would happen, I tried running the Emacs server in a batch session and then calling "emacsclient -c -nw": emacs -Q --batch --eval '(progn (server-start) (while t (sit-for 1)))' emacsclient -c -nw Surprisingly, it seems to mostly work, although it echoes control characters to the screen. Anyway, here's a patch for this. Maybe there's a better way to do it, but this seemed like the least-invasive.