Skip to content

fix(findNvim): skip default dirs if cmds is given - #556

Merged
justinmk merged 1 commit into
masterfrom
findnvim
Sep 11, 2026
Merged

justinmk merged 1 commit into
masterfrom
findnvim

Conversation

@justinmk

@justinmk justinmk commented Sep 11, 2026

Copy link
Copy Markdown
Member

Problem:
No way for caller to skip the default dir search, which makes it awkward
to check if the found result was part of the caller's specified cmds
or a "default" location.

Solution:

  • Skip searching default locations if cmds is given. Callers are
    expected to call findNvim() a 2nd time if they want to also search
    default locations.
  • Throw an error if both cmds and dirs are given.

followup to #432

Problem:
No way for caller to skip the default dir search, which makes it awkward
to check if the found result was part of the caller's specified `cmds`
or a "default" location.

Solution:
- Skip searching default locations if `cmds` is given. Callers are
  expected to call `findNvim()` a 2nd time if they want to also search
  default locations.
- Throw an error if both `cmds` and `dirs` are given.
@justinmk
justinmk merged commit 91b73e8 into master Sep 11, 2026
8 checks passed
@justinmk
justinmk deleted the findnvim branch September 11, 2026 15:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant