rclone/cmd/genautocomplete/genautocomplete.go

24 lines
570 B
Go
Raw Normal View History

// Package genautocomplete provides the completion command.
package genautocomplete
import (
"github.com/rclone/rclone/cmd"
"github.com/spf13/cobra"
)
func init() {
2017-08-31 14:52:51 +00:00
cmd.Root.AddCommand(completionDefinition)
}
2017-08-31 14:52:51 +00:00
var completionDefinition = &cobra.Command{
Use: "completion [shell]",
2017-08-31 14:52:51 +00:00
Short: `Output completion script for a given shell.`,
Long: `Generates a shell completion script for rclone.
Run with ` + "`--help`" + ` to list the supported shells.
`,
Annotations: map[string]string{
"versionIntroduced": "v1.33",
},
Aliases: []string{"genautocomplete"},
}