Function: forge--batch-add-callback

forge--batch-add-callback is a natively compiled function defined in forge-github.el.

Signature

(forge--batch-add-callback HOST OWNER NAMES)

Source Code

;; Defined in /nix/store/923zwib42c4qw6x4xps0cv1wi8qcd6lp-emacs-packages-deps/share/emacs/site-lisp/elpa/forge-20261005.753/forge-github.el
(defun forge--batch-add-callback (host owner names)
  (let ((repos (mapcan (lambda (name)
                         (let ((repo (forge-get-repository
                                      (list host owner name)
                                      nil :insert!)))
                           (and (not (forge-get-repository repo nil :tracked?))
                                (list repo))))
                       names))
        (cb nil))
    (setq cb (lambda (_)
               (when-let ((next (pop repos)))
                 (forge--pull next cb))))
    (funcall cb)))