Function: magit-todos-item-first-path-component

magit-todos-item-first-path-component is a natively compiled function defined in magit-todos.el.

Signature

(magit-todos-item-first-path-component ITEM)

Documentation

Return ITEM's first directory.

This assumes that ITEM's filename is already set to a path relative to the repo's directory (i.e. this would not be very useful with absolute paths).

Source Code

;; Defined in /nix/store/xy37aj9089qvbs5clw0qszpi3hrh3mxx-emacs-packages-deps/share/emacs/site-lisp/elpa/magit-todos-20250928.1611/magit-todos.el
(defun magit-todos-item-first-path-component (item)
  "Return ITEM's first directory.
This assumes that ITEM's filename is already set to a path
relative to the repo's directory (i.e. this would not be very
useful with absolute paths)."
  (car (f-split (magit-todos-item-filename item))))