0

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 script:

(defun hello-world-process-sentinel (process event)
  (message "Process: %s; Event: %s" process event))

(defvar hello-world-process (make-process :name "hello world"
                                        :buffer (get-buffer-create "*hello world*")
                                        :command "hello-world"
                                        :sentinel #'hello-world-process-sentinel))

(process-status hello-world-process) returns run, but the *hello world* buffer stays empty, and the sentinel doesn't get called.

1

Use :command '("hello-world") instead. Here is the related docstring of make-process.

:command COMMAND -- COMMAND is a list starting with the program file name, followed by strings to give to the program as arguments.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.