EN
← 错误索引

F_SYSTEM_INVALID_COMPLETION_BIN

补全命令名无效

func/completion 收到的 bin 为空、包含空白或包含 NUL 字符。

更新于

复现

bin 必须是 shell 中实际输入的一个命令 token:

src/index.ts
import { withCompletion } from 'func/completion'

withCompletion({ bin: 'my cli' })

如何修复

使用 package.json#bin 中对应的键,例如 withCompletion({ bin: 'my-cli' })。标点可以使用,但值不能为空、不能包含空白或 NUL。无效值位于 details.bin