Open BenoitRanque opened 3 years ago
It looks like current completion is being done just through leveraging cobra's built-in completion functionality.
Given that, is this change much more complicated than just adding a case statement like the following (and updating completionCmdExample
?
case "pwsh":
if o.File != "" {
err = o.Cmd.Root().GenPowerShellCompletionFile(o.File)
} else {
err = o.Cmd.Root().GenPowerShellCompletion(os.Stdout)
}
If so, I'd be happy to contribute a PR to take care of this.
Hasura completion currently supports bash and zsh.
Tab completion is now possible in powershell, with
Set-PSReadlineKeyHandler -Key Tab -Function MenuComplete
There is also the Register-ArgumentCompleter cmdlet which could be used to implement this.
Hasura's completion should include this shell.