We changed our privacy policy. Read more.

Questions tagged [process]

A process is a running instance of a program. Use this tag for how Emacs interacts with programs that it runs (compilers, viewers, network backends, etc.)

Filter by
Sorted by
Tagged with
0
votes
1answer
20 views

Automatically change encoding of process buffers

Platform Windows 10 with GNU Emacs 26.1 (build 1, x86_64-w64-mingw32). Goal To set the encoding of process buffers to UTF-8. I would like to set the input and output encoding of process buffers, like ...
0
votes
0answers
14 views

start-process permissions in Windows

I can open an HTML file using shell command: M-! start file.html, but when I try to write an elisp function which includes the line (some of these arguments are actually variables but I've written out ...
0
votes
1answer
15 views

Can't send/receive OSC messages to/from other processes

I made my first attempt at OSC with (Doom) Emacs. I got the example in osc.el working, but I couldn't make it either send or receive messages to/from other processes, even if they are running in ...
0
votes
0answers
18 views

[Emacs 28.0.50][Windows 10] Start process "love2d" which is attached to the console

I am developing a game with the love2d lua API and with emacs as IDE. In order to easily test the game from emacs, I wrote following functions : (defgroup love nil "The customization group ...
0
votes
2answers
31 views

Looking for a better way to test whether the current Emacs process is running under GNU Screen

NB: For the sake of this question, please assume that the underlying OS is some flavor of Unix. If more specificity is required, then please assume that it is either Darwin or some flavor of Linux. ...
0
votes
1answer
97 views

Get process id (pid) for running python (jupyter-kernel)

I've started a jupyter kernel form emacs-jupyter. I'd like to get the process id for the python process associated with the buffer so that I can attach a debugger to it. How can I do this in elisp?
1
vote
0answers
25 views

Why are eight-bit single-byte characters counted as multibyte with (byte-to-position)?

I was investigating a problem with how an Emacs process (monroe.el) decodes messages formatted in bencode, where the process would not skip over the correct number of characters in the message, ...
0
votes
1answer
176 views

Cannot use `pbpaste` in Emacs to paste Chinese characters

I'm using macOS. I tried using the following command to paste from clipboard in Emacs(started with emacs -Q) (call-process "/usr/bin/pbpaste" nil t nil) It works fine for English characters,...
0
votes
1answer
44 views

How to use Emacs to prevent screen lock from activating (Windows)

My employer has a pretty paranoid screen locking policy on Windows machines. There's no way to override the time settings for the lock. My colleagues an I have been experimenting with various homebrew ...
0
votes
1answer
78 views

How to start a process with multiple arguments?

Instead running sudo su joe -s prime-run firefox in the shell I'd rather bind it to a key. Yet, nothing happens on pressing M-n (while M-i works). What am I doing wrong? (setq exwm-input-global-keys ...
0
votes
0answers
29 views

Bizarre behaviour using `call-process': cabal fails as if it is in wrong directory, but succeeds with 'cd ./ ; cabal'

I'm trying to get haskell-mode working on Windows but something funny is happening and I've traced my problems using Edebug into the bowels of emacs: Can someone explain the following strange ...
0
votes
1answer
143 views

How can I re-enable `C-z` in evil mode (to pause Emacs)?

I have been using Emacs for a while and recently started using evil mode. I exclusively use emacs-nox (command line emacs). The only thing that's missing for me is C-z to pause emacs and bring me back ...
0
votes
0answers
49 views

Finitizing infinite comint output

Context I'm a teacher and I often want to show “bad” programs; in this case infinite outputting programs. But while I want to show the bad I dont want my laptop crashing in class (nowadays on zoom) ...
2
votes
0answers
88 views

Process sentinels don't run during init in GUI Emacs

Ok, this issue I'm running into seems pretty weird. I'm running an async process during init and I have set a process sentinel to tell me when it exits. This works fine in terminal Emacs but in GUI ...
0
votes
1answer
58 views

Start Process Not Working: Process List Claims Process Started but Process UI not shown

Start Process is not working when starting GUI application in WSL on Windows 10 Pro. I am calling Start Process as follows. (start-process "yekneb-exec-2" nil "/mnt/c/WINDOWS/explorer....
1
vote
0answers
64 views

Why does calling `term-send-backspace` (just pressing backspace) create a newline in the `*terminal*` buffer in `term-mode`?

Specs: i@debord:~$ emacs --version GNU Emacs 26.3.50 Copyright (C) 2019 Free Software Foundation, Inc. GNU Emacs comes with ABSOLUTELY NO WARRANTY. You may redistribute copies of GNU Emacs under the ...
2
votes
1answer
144 views

Process shell exited abnormally with code 53 on windows 10

I'm using emacs 26.2 installed through msys2. Recently starting subprocesses from emacs has stopped working for me. Specifically M-x shell and shell-command-to-string. I get the feeling this is due to ...
0
votes
0answers
28 views

Is it possible to control DTR and/or RTS for a serial process (serial-term)?

I create a serial port process with (serial-term), or the underlying (make-serial-process ...). Is it possible to control the DTR and/or RTS pins for the port from within Emacs? Looking at the source ...
0
votes
0answers
41 views

Can emacs control other programs windows?

I am using start-process to start other programs as part of my workflow. For example starting a browser to display the HTML file I am working on, or Visual Studio to debug the EXE I just compiled. ...
1
vote
0answers
133 views

Elpy: how to stop the underlying RPC process?

Whenever elpy-mode is activated upon visiting a python file, I see a py.exe executable start, with a subtree of processes. This should be the remote procedure call (thanks @al0 for the explanation). ...
2
votes
1answer
136 views

How to pipe data through multiple processes?

Currently I'm generating text from a command, eg: (with-temp-buffer (call-process "my-command" nil t nil "my" "args") ;; operate on output in current buffer. ) How can I use pipes, something ...
2
votes
1answer
273 views

Get process id for the Emacs own process

I'm supporting some elisp code that creates a temporary filename using a prefix and the user id. When I develop this, that is not enough since I will be running multiple instances concurrently. So I'...
1
vote
0answers
40 views

Send a command to Emacs from an inferior process

Is it possible to send a command to Emacs from an inferior process? For my particular use-case, I would like to instruct Emacs to run the command inferior-ess-r-reload-hook (part of the ESS package) ...
0
votes
1answer
41 views

Clojure nrepl: 'cider-jack-in returns error: "Spawning child process: Invalid argument"

Running GNUEmacs 26.3 on Windows 10, trying to set up environment per instructions for 'Clojure for the Brave and True' from here: https://github.com/flyingmachine/emacs-for-clojure/ I was able to ...
0
votes
1answer
122 views

how can I change the inferior Python process

I would like to be able to start Python 3 and ipython from Emacs in an inferior mode buffer. Currently start interpreter C-c C-p starts 2.7. I know there must be a way to change to start another ...
2
votes
1answer
92 views

How can I query Emacs from a separate process?

I'm interested in tracking how I spend my time at work. I have been using ManicTime, and it does much of what I want. However, I use Emacs as my primary editor, and ManicTime doesn't know how to get ...
1
vote
1answer
41 views

Troubleshooting a hanging `list-processes`

Normally I'd use M-x list-processes to see what Emacs is running in the background. But in this case list-processes itself hangs. What is the right thing to do in this situation?
0
votes
1answer
56 views

Is variable assignment an atomic operation in elisp?

I have a situation in a mode I'm writing that saves a portion of the output of a long-running asynchronous process to a variable at intermittent intervals. I need to access this data periodically. My ...
1
vote
1answer
53 views

Lexical binding in a process filter

The code constantly prints server-process: nil instead of the server process name: -*- lexical-binding: t; -*- (let* ((port 1234) (server-process 'something)) (setq server-process (...
0
votes
1answer
99 views

“call-process” hangs and does not launch the program

I’m dipping my toes into reading news with Gnus. I’d like to continue using the same editor as before for composing posts, so I put these forms in my gnus.el: (setq message-tab-body-function 'edit-in-...
1
vote
1answer
73 views

How can I tell when non-interactive bash process is done executing a command?

I'm trying to write a different shell command line interface where the input line stays at the top. Output of previous commands should stack below: > INPUT LINE LAST OUTPUT (of command 1) ...
4
votes
3answers
325 views

How to determine which program is running inside an emacs shell buffer?

I have an emacs shell buffer which may or may not be running a certain interactive program such as ftp or python. I wish to write a lisp function which will interact with this program, but I would ...
0
votes
0answers
52 views

How can I make multiple calls to external binaries?

I want to write an interactive function to Call an external binary Write the output of the binary into a buffer Process the buffer to extracts args for next call Call another external binary using ...
5
votes
1answer
180 views

Send content of region or current line to a tmp file, then execute shell script with filename as argument

I am transitioning to Emacs with evil-mode after years of Vim. For work reasons I have to use a GUI statistics program (Stata) frequently. This program does not integrate well with external editors. ...
0
votes
1answer
41 views

Replacement for the sit-for function

Using currently the sit-for function, every time i hit any key and cause user input the sit-for will stop. Is there any possibility to have something like sit-for, while being able to move the cursor ...
1
vote
1answer
96 views

How to create shortcut that will kill process for buffer with fixed name

I have code like this to run R command from Emacs: (defun call-r-command (command-list) "run R command in shell buffer window if there is displayed buffer that have shell it will use that window"...
4
votes
1answer
87 views

How to partially block user input while Emacs subprocess is running

I have a custom function that updates the etags file before prompting the user to input a desired tag to be located. Although I am pretty good about setting the current buffer to read-only before ...
1
vote
1answer
89 views

Launch ncurses application and cleanup once it exits

I'd like to occasionally use hg split and hg commit --interactive from Emacs, but those commands bring up a GUI. At the moment I either use a separate terminal or ansi-term for those, but would like ...
1
vote
0answers
142 views

How to kill a running process in compilation buffer in MS Windows?

I have tried using M-x kill-compilation and it doesn't kill the process (on Microsoft Windows). It just sends ^C, which makes my script to retry. When I try to M-x kill-buffer on the compilation ...
0
votes
0answers
33 views

Emacs report a process which does not exist

When start Emacs from the terminal as me@mbp: ~$ emacs --deamon It prompts that However, there does not exist such a pocesses me@mbp~$ ps 8559 PID TTY STAT TIME COMMAND me@mbp:~$ ps -el ...
1
vote
1answer
157 views

Open another emacs and cause conflicts

I have a GUI emacs running as the major working area, When I reading articles from web, need to open a emacs as a tool to keep note; Web on the left and new emacs on the right, Usually, get ...
1
vote
0answers
91 views

Unknown *emacs* process

I recently realized that every time I lunch emacs, after a minute, a strange buffer appear in buffers list that is linked to an emacs process, infact it also appear in system's process list: When I ...
1
vote
0answers
160 views

How to make process in compilation-mode think it's not running in interactive terminal?

I use minitest-mode which starts Ruby tests in compilation-mode: (compilation-start actual-command 'minitest-compilation-mode (lambda (arg) (minitest-buffer-name (or file-name "")))) Tests invoke ...
0
votes
1answer
43 views

External process hangs

I have written a simple Python 3 script: #!/usr/bin/env python3 print('Hello world!') The script works from the shell: $ ./hello-world Hello world! Then, I have written some Lisp to run the ...
1
vote
1answer
134 views

Why does :command argument of make-process not work when string passed as a variable? [duplicate]

This works fine: (make-process :name "my-proc2" :buffer " *my-proc2*" :command '("sh" "-c" "echo \"hi\"\nsleep 10\necho \"there\"") :connection-type 'pipe :...
2
votes
2answers
821 views

Kill inferior python in python.el mode

At the moment I am killing the Python interpreter with C-d each time I want to quit Python interpreter. What is the name of the function to kill the Python interpreter in Python mode (the one which ...
0
votes
1answer
68 views

Inconsistent point in an elisp program and in a visible non-focused process buffer

I am able to collect output data from a process, but I don't understand the coordination of point and process-mark. In particular, the visible cursor in a non-selected window visiting the buffer does ...
0
votes
1answer
138 views

Asynchrony when collecting output in a process buffer?

I want to capture output from a process buffer. This is not a duplicate of How do I reliably get output from a process? because that questioner is presupposing comint and an architecture for a ...
0
votes
2answers
269 views

shell command on region with process substitution

If I want to execute a shell command on a region I know I can use shell-command-on-region via M-|, what if the command I want to redirect my selection does not accept redirection to it's standard ...
0
votes
1answer
35 views

How Can I Prevent make-process from failing if the default-directory doesn't exist?

Usually, when you open a file, Emacs prompts you to run M-x make-directory RET RET if the directory doesn't exist. However, after writing my own advice, I realized that opening files in directories ...