mirror of
https://github.com/junegunn/fzf.git
synced 2026-10-15 10:32:49 +08:00
Nushell 0.116 runs an external completer on a background worker without the terminal unless the registered closure reaches a command carrying the @interactive attribute. Interactivity is seen through the closure to the command it calls, so wrap the completion logic in an @interactive entry point and register a closure that ends with the call to it. Read the named `place` input instead of the deprecated positional `spans`; $place.command carries the same token list. An @interactive completer cannot decline with null (null reads as a dismissed picker), so request the fallback explicitly when the `**` trigger is absent, keeping plain file completion working. The previous external completer is still called when the trigger is absent. The script now requires Nushell 0.116+, since @interactive is a parse error on older versions. Fixes #4932