I have a function workbench-named
declared as follows, that calls another one called workbench
. Have changed workbench
to include a prefix argument. Thusly workbench-named
is not calling workbench
properly as it assumes that name is the first argument.
How can I modify the call to workbench
from the function workbench-named
?
(defun workbench-named ()
"Generate new temporary buffer by asking for buffer name."
(interactive)
(workbench (read-from-minibuffer " Name: ")))
(defun workbench (&optional prefix name mode)
"Make new temporary buffer.")
(workbench nil (read-from-minibuffer " Name: ")))
to provide the expected first argument. – Fran Burstall Jun 30 '22 at 13:52"
, etc. – Drew Jun 30 '22 at 15:50workbench
rather than worrying about any ending"
. – Dilna Jun 30 '22 at 19:40(interactive "sName: ")
to make the function ask for a name when called as a command, but use the argument passed to it when called as a function. – Lindydancer Jun 30 '22 at 20:14