Skip to content

fix: install, not update, when fisher updates fish-ai that isn't installed yet - #915

Open
tsvikas wants to merge 1 commit into
Realiserad:mainfrom
tsvikas:update-before-install
Open

tsvikas wants to merge 1 commit into
Realiserad:mainfrom
tsvikas:update-before-install

Conversation

@tsvikas

@tsvikas tsvikas commented Nov 20, 2026

Copy link
Copy Markdown

When fisher's own records say fish-ai is installed but it isn't, as on a new machine whose fish_variables comes from a dotfiles repo, the first fisher update emits fish_ai_update rather than fish_ai_install.
The update hook then calls $_fish_ai_install_dir/bin/lookup_setting before the virtual environment exists, and prints fish: Unknown command: .../bin/lookup_setting (it then goes on to create the environment).

This makes the update hook run the install hook and return when bin/lookup_setting isn't there yet, after the old directory and config moves, which may put an installation in place.

Tested with fish --no-config, sourcing conf.d/fish_ai.fish with _fish_ai_install stubbed: with no installation directory the update calls the install hook; with one, it doesn't.
Version bumped to 2.22.1 by hand (the bump-version hook needs what-bump); this collides with #914, which bumps to the same version.

🤖 Generated with Claude Code

…alled yet

fisher counts a plugin as installed when its fish variables say so. When
those come from another machine (fish_variables in a dotfiles repo), a new
machine's first `fisher update` runs the update hook, which asked the
not-yet-created virtual environment for a setting and printed
'Unknown command: .../bin/lookup_setting'. Run the install hook instead.
@github-actions github-actions Bot added the size/XS Pull request with less than 10 lines of code label Nov 20, 2026
@tsvikas
tsvikas marked this pull request as ready for review November 20, 2026 04:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/XS Pull request with less than 10 lines of code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant