partizan<p>Can we please have one standard way to define shell completions, that is compatible with all shells?</p><p>I'm moving from zsh to nushell, and it's relatively new, and you have to configure completions by writing a lot of code, including a lot of files, it's a nightmare.</p><p>It's easier for older shells like zsh or fish only because other people already done it, and some packages include per-shell completions.</p><p>There is <span class="h-card" translate="no"><a href="https://mastodon.social/@carapace_sh" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>carapace_sh</span></a></span> which attempts to do the right thing, but having completions in the other place than actual app is not very good idea.</p><p><a href="https://usage.jdx.dev/" rel="nofollow noopener" translate="no" target="_blank"><span class="invisible">https://</span><span class="">usage.jdx.dev/</span><span class="invisible"></span></a> is trying to do the same but differently, and it has a way for an app to provide a schema for completions. This is step in the right direction, but not many tools support this.</p><p>Has anyone tried to put this somehow on the shell level? E.q. app includes a file like `myapp.completions` , and shell have a module which reads the file and generates a list of completions based on user input.</p><p>The right way to do this, is probably by defining a standard cross-platform/cross-shell schema. And it can be read by the shell, or by the tool like carapace or usage...</p><p><a href="https://twiukraine.com/tags/Linux" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Linux</span></a> <a href="https://twiukraine.com/tags/zsh" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>zsh</span></a> <a href="https://twiukraine.com/tags/bash" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>bash</span></a> <a href="https://twiukraine.com/tags/nushell" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>nushell</span></a> <a href="https://twiukraine.com/tags/fish" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>fish</span></a> <a href="https://twiukraine.com/tags/elvish" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>elvish</span></a></p>