Function: projection-multi-projection-targets
projection-multi-projection-targets is a natively compiled function
defined in projection-multi.el.
Signature
(projection-multi-projection-targets &optional PROJECT-TYPE-PREFIX PROJECT)
Documentation
compile-multi target generator function for projection-commands in PROJECT.
When set the generated targets will be prefixed with PROJECT-TYPE-PREFIX. If not set PROJECT will be determined automatically.
The generated candidates will be of the form prefix:project-type:project-command.
Source Code
;; Defined in /nix/store/p352vg5hx7hmw07f7hjwfyrih9p75bzv-emacs-packages-deps/share/emacs/site-lisp/elpa/projection-multi-20260614.1822/projection-multi.el
;;;###autoload
(defun projection-multi-projection-targets (&optional project-type-prefix project)
"`compile-multi' target generator function for `projection-commands' in PROJECT.
When set the generated targets will be prefixed with PROJECT-TYPE-PREFIX. If
not set PROJECT will be determined automatically.
The generated candidates will be of the form
prefix:project-type:project-command."
(setq project-type-prefix (or project-type-prefix "projection"))
(when-let* ((project (or project (projection--current-project 'no-error)))
(current-project-types
(projection-project-types (project-root project))))
(let (result)
(dolist (project-config current-project-types)
(dolist (cmd-type-config projection-commands--registered-cmd-types)
(when-let* ((cmd
(projection-commands--ignore-no-command
(funcall (cadr cmd-type-config) project project-config :use-cache nil))))
(push `(,(concat project-type-prefix ":"
(symbol-name (oref project-config name)) ":"
(symbol-name (car cmd-type-config)))
:command ,(lambda () (interactive)
(funcall-interactively (caddr cmd-type-config) project cmd))
:annotation ,(when (stringp cmd) cmd))
result))))
(nreverse result))))