reddit / emacs

Why is shell emacs -f different than M-x?

WorldsEndless · 2022-09-23 12:09
I can do a `M-& emacs` followed therein by `M-x telega` and it seems this is not the same as doing `M-& emacs -f telega` (resulting in a frozen emacs, like when I do `M-x telega` in my main exwm process). Shouldn't these be the same?
7890yuiop · 2022-09-23 12:40
One call is interactive, the other is not.
WorldsEndless · 2022-09-23 13:22
Is there anything I can do about that? Is there a "make the -f call interactive"?
7890yuiop · 2022-09-23 13:55
No; `-f` makes a non-interactive call to a function, just like `(telega)` would in elisp code. You could use `--eval "(call-interactively #'telega)"` though.