Variable: projectile-async-indexing

projectile-async-indexing is a customizable variable defined in projectile.el.

Value

t

Documentation

Whether to index projects without freezing Emacs.

When non-nil, the external-command indexing methods (alien and hybrid) run their indexing command asynchronously and wait for it in a way that keeps Emacs responsive to redisplay and keyboard-quit (C-g (keyboard-quit)), instead of blocking until the command finishes. This matters most on large projects and on remote (TRAMP) hosts, where a cold projectile-find-file could otherwise freeze Emacs for seconds.

The resulting file list is identical to the synchronous path; only the responsiveness during indexing differs. Has no effect under native indexing (the Emacs Lisp directory walk cannot run off the main thread), in batch mode, or while a keyboard macro is executing - those fall back to synchronous indexing.

This variable was added, or its default value changed, in projectile version 3.0.0.

Source Code

;; Defined in ~/.emacs.d/elpa/projectile-20260820.1509/projectile.el
(defcustom projectile-async-indexing t
  "Whether to index projects without freezing Emacs.

When non-nil, the external-command indexing methods (`alien' and
`hybrid') run their indexing command asynchronously and wait for it in a
way that keeps Emacs responsive to redisplay and `keyboard-quit' (\\[keyboard-quit]),
instead of blocking until the command finishes.  This matters most on
large projects and on remote (TRAMP) hosts, where a cold
`projectile-find-file' could otherwise freeze Emacs for seconds.

The resulting file list is identical to the synchronous path; only the
responsiveness during indexing differs.  Has no effect under `native'
indexing (the Emacs Lisp directory walk cannot run off the main thread),
in batch mode, or while a keyboard macro is executing - those fall back
to synchronous indexing."
  :group 'projectile
  :type 'boolean
  :package-version '(projectile . "3.0.0"))