Refactor: Remove powershell support
authorBen Mezger <me@benmezger.nl>
Tue, 2 Feb 2021 23:02:53 +0000 (20:02 -0300)
committerAnthony Fok <foka@debian.org>
Thu, 4 Feb 2021 22:32:51 +0000 (15:32 -0700)
commands/genautocomplete.go
docs/content/en/commands/hugo_gen_autocomplete.md

index b72e5a93054dc8f12337cf649013f7dcf36e626a..044a052e69f5d4767c03a881484f02c2f7ec80b6 100644 (file)
@@ -22,10 +22,8 @@ var _ cmder = (*genautocompleteCmd)(nil)
 
 type genautocompleteCmd struct {
        autocompleteTarget string
-
-       // bash or zsh
+       // bash, zsh or fish
        autocompleteType string
-
        *baseCmd
 }
 
@@ -45,7 +43,7 @@ for convenience, and the command may need superuser rights, e.g.:
 Add ` + "`--completionfile=/path/to/file`" + ` flag to set alternative
 file-path and name.
 
-Add ` + "`--type={bash, zsh, fish or powershell}`" + ` flag to set alternative
+Add ` + "`--type={bash, zsh or fish}`" + ` flag to set alternative
 shell type.
 
 Logout and in again to reload the completion scripts,
@@ -62,8 +60,6 @@ or just source them in directly:
                                err = cmd.Root().GenBashCompletionFile(cc.autocompleteTarget)
                        case "fish":
                                err = cmd.Root().GenFishCompletionFile(cc.autocompleteTarget, true)
-                       case "powershell":
-                               err = cmd.Root().GenFishCompletionFile(cc.autocompleteTarget, true)
                        default:
                                return newUserError("Unsupported completion type")
                        }
index fe3916309622ccb27a89cf59f882ba80b9a6f44d..033e4fa820365a96094a4f9f2335567db6ce6dcb 100644 (file)
@@ -20,7 +20,7 @@ for convenience, and the command may need superuser rights, e.g.:
 Add `--completionfile=/path/to/file` flag to set alternative
 file-path and name.
 
-Add `--type={bash, zsh, fish or powershell}` flag to set alternative
+Add `--type={bash, zsh or fish}` flag to set alternative
 shell type.
 
 Logout and in again to reload the completion scripts,
@@ -37,7 +37,7 @@ hugo gen autocomplete [flags]
 ```
       --completionfile string   autocompletion file (default "/etc/bash_completion.d/hugo.sh")
   -h, --help                    help for autocomplete
-      --type string             autocompletion type (zsh, bash, fish or powershell) (default "bash")
+      --type string             autocompletion type (zsh, bash or fish) (default "bash")
 ```
 
 ### Options inherited from parent commands