Function: projectile--restrict-to-subdirs
projectile--restrict-to-subdirs is a byte-compiled function defined in
projectile.el.
Signature
(projectile--restrict-to-subdirs FILES SUBDIRS)
Documentation
Keep only the FILES that live under one of SUBDIRS.
FILES and SUBDIRS are both relative to the project root. Returns FILES unchanged when SUBDIRS is nil.
Source Code
;; Defined in ~/.emacs.d/elpa/projectile-20260820.1509/projectile.el
(defun projectile--restrict-to-subdirs (files subdirs)
"Keep only the FILES that live under one of SUBDIRS.
FILES and SUBDIRS are both relative to the project root. Returns FILES
unchanged when SUBDIRS is nil."
(if (null subdirs)
files
(let ((normalized (mapcar #'file-name-as-directory subdirs)))
(seq-filter
(lambda (f)
(seq-some (lambda (sd) (string-prefix-p sd f)) normalized))
files))))