Function: magit-read-file
magit-read-file is a byte-compiled function defined in magit-files.el.
Signature
(magit-read-file PROMPT &optional TRACKED-ONLY)
Source Code
;; Defined in ~/.emacs.d/elpa/magit-20260411.1452/magit-files.el
(defun magit-read-file (prompt &optional tracked-only)
(let ((choices (nconc (magit-list-files)
(and (not tracked-only)
(magit-untracked-files)))))
(magit-completing-read
prompt choices nil t nil nil
(car (member (or (magit-section-value-if '(file submodule))
(magit-file-relative-name nil tracked-only))
choices)))))