Function: magit-list-untracked-files
magit-list-untracked-files is a byte-compiled function defined in
magit-git.el.
Signature
(magit-list-untracked-files &optional FILES)
Documentation
Return a list of untracked files.
List files if magit-status-show-untracked-files is non-nil, but also
take the local value of Git variable status.showUntrackedFiles into
account. The local value of the Lisp variable takes precedence over the
local value of the Git variable. The global value of the Git variable
is always ignored.
See also magit-untracked-files.
Source Code
;; Defined in ~/.emacs.d/elpa/magit-20260411.1452/magit-git.el
(defun magit-list-untracked-files (&optional files)
"Return a list of untracked files.
List files if `magit-status-show-untracked-files' is non-nil, but also
take the local value of Git variable `status.showUntrackedFiles' into
account. The local value of the Lisp variable takes precedence over the
local value of the Git variable. The global value of the Git variable
is always ignored.
See also `magit-untracked-files'."
(and-let*
((value (or (and (local-variable-p 'magit-status-show-untracked-files)
magit-status-show-untracked-files)
(pcase (magit-get "--local" "status.showUntrackedFiles")
((or "no" "off" "false" "0") 'no)
((or "yes" "on" "true" "1") t)
("all" 'all))
magit-status-show-untracked-files))
(_(not (eq value 'no))))
(seq-keep (##and (eq (aref % 0) ??)
(substring % 3))
(apply #'magit-git-items "status" "-z" "--porcelain"
(format "--untracked-files=%s"
(if (eq value 'all) "all" "normal"))
"--" files))))