如何编写bash completion script

创建静态补全很简单,只需要使用 complete 的 -W (wordlist) 选项为脚本注册补全的单词列表就行了。 (by 暗无天日) ​​​