Function: projectile--ag-ignore-patterns
projectile--ag-ignore-patterns is a byte-compiled function defined in
projectile.el.
Signature
(projectile--ag-ignore-patterns)
Documentation
Return ag-ignore-list entries for the project's ignore patterns.
They come from projectile--ignore-patterns. ag takes plain globs
with no notion of anchoring, so the gitignore markers it wouldn't make
sense of - a leading / or **/, a trailing / - are stripped; what's
left matches at any depth, which is as close as ag gets.
Source Code
;; Defined in ~/.emacs.d/elpa/projectile-20260820.1509/projectile.el
(defun projectile--ag-ignore-patterns ()
"Return `ag-ignore-list' entries for the project's ignore patterns.
They come from `projectile--ignore-patterns'. `ag' takes plain globs
with no notion of anchoring, so the gitignore markers it wouldn't make
sense of - a leading `/' or `**/', a trailing `/' - are stripped; what's
left matches at any depth, which is as close as `ag' gets."
(seq-remove
#'string-empty-p
(mapcar (lambda (pattern)
(let ((body (string-remove-suffix "/" pattern)))
(cond ((string-prefix-p "**/" body) (substring body 3))
((string-prefix-p "/" body) (substring body 1))
(t body))))
(projectile--ignore-patterns))))