(Regarding shell completions in general)
Generally, my process for writing is google around until I have some base level of knowledge, then building one or more demo applications to ensure my understanding is correct. Then as I'm writing the blog post I'll be refining the demo applications into examples for the blog post and/or library code that I want to open source.
[0]: https://www.gnu.org/software/bash/manual/html_node/Programma... [1]: https://www.gnu.org/software/bash/manual/html_node/Programma... [2]: https://hackaday.com/2018/01/19/linux-fu-custom-bash-command... [3]: https://github.com/scop/bash-completion [4]: https://github.com/git/git/blob/master/contrib/completion/gi...
https://tylerthrailkill.com/2019-01-13/writing-zsh-completio... https://tylerthrailkill.com/2019-01-19/writing-bash-completi...
I need to improve them and write a bit more information, I was writing a library to generate completion scripts for both bash and zsh, so I had to know the differences quite well.
I wonder if the API for windows auto-completion is sophisticated enough that you could add cross-platform support for this.