Files
taylor.fish 08e5d0986d fix(search): prepare daemon search index in shell init scripts (#3864)
Fixes #3857. In the shell init scripts, tell the daemon to build the
search index so it's ready by the time the user executes the first
query.

The daemon currently builds the index when it starts, but if a user has
`search.shells = "auto"` in config.toml (the default), the daemon can't
always know which shell the user is actually going to be using, and thus
can't build the correct index.

The init script provided by `atuin init`, however, knows exactly which
shell is in use, and thus can signal the daemon to build the correct
index.

### Implementation details

This PR adds a new hidden command, `atuin __internal
prepare-search-index`. If the user has selected the daemon-fuzzy engine,
this command will send a new gRPC message, `PrepareIndexRequest`, to the
daemon. The call to `atuin __internal prepare-search-index` is executed
as a background job in the shell init scripts to avoid blocking the
shell, and with stdout/stderr silenced.
2026-08-06 22:20:53 -04:00
..