Function: magit--insert-modules-logs
magit--insert-modules-logs is a byte-compiled function defined in
magit-submodule.el.
Signature
(magit--insert-modules-logs HEADING TYPE RANGE)
Documentation
For internal use, don't add to a hook.
Source Code
;; Defined in ~/.emacs.d/elpa/magit-20260411.1452/magit-submodule.el
(defun magit--insert-modules-logs (heading type range)
"For internal use, don't add to a hook."
(when-let ((_(not (magit-ignore-submodules-p)))
(modules (magit-list-module-paths)))
(magit-insert-section ((eval type) nil t)
(string-match "\\`\\(.+\\) \\([^ ]+\\)\\'" heading)
(magit-insert-heading
(propertize (match-str 1 heading)
'font-lock-face 'magit-section-heading)
" "
(propertize (match-str 2 heading)
'font-lock-face 'magit-branch-remote)
":")
(dolist (module modules)
(when-let* ((default-directory (expand-file-name module))
(_(file-exists-p (expand-file-name ".git")))
(lines (magit-git-lines "-c" "push.default=current"
"log" "--oneline" range))
(count (length lines))
(_(> count 0)))
(magit-insert-section
( module module t
:range range)
(magit-insert-heading count
(propertize module 'font-lock-face 'magit-diff-file-heading))
(dolist (line lines)
(string-match magit-log-module-re line)
(let ((rev (match-str 1 line))
(msg (match-str 2 line)))
(magit-insert-section (module-commit rev t)
(insert (propertize rev 'font-lock-face 'magit-hash) " "
(magit-log--wash-summary msg) "\n")))))))
(magit-cancel-section 'if-empty)
(insert ?\n))))