Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bridge: removed ActionPosener and fixed references #1534

Merged
merged 1 commit into from
Mar 6, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion cmd/carapace/cmd/bridge.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ func createCmd(command string, engine string) *cobra.Command {
case "fish":
return bridge.ActionFish(command)
case "posener":
return bridge.ActionPosener(command)
return bridge.ActionComplete(command)
default:
return carapace.ActionValues()
}
Expand Down
2 changes: 1 addition & 1 deletion completers/boundary_completer/cmd/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@ func init() {

carapace.Gen(rootCmd).PositionalAnyCompletion(
// TODO just bridging it for now
bridge.ActionPosener("boundary"),
bridge.ActionComplete("boundary"),
)
}
2 changes: 1 addition & 1 deletion completers/nomad_completer/cmd/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@ func init() {

carapace.Gen(rootCmd).PositionalAnyCompletion(
// TODO just bridging it for now
bridge.ActionPosener("nomad"),
bridge.ActionComplete("nomad"),
)
}
2 changes: 1 addition & 1 deletion completers/vault_completer/cmd/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@ func init() {

carapace.Gen(rootCmd).PositionalAnyCompletion(
// TODO just bridging it for now
bridge.ActionPosener("vault"),
bridge.ActionComplete("vault"),
)
}
2 changes: 1 addition & 1 deletion pkg/actions/bridge/argcomplete.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"github.com/rsteube/carapace"
)

// ActionArgcomplete bridges kislyuk/argcomplete
// ActionArgcomplete bridges https://github.com/kislyuk/argcomplete
//
// var rootCmd = &cobra.Command{
// Use: "az",
Expand Down
4 changes: 2 additions & 2 deletions pkg/actions/bridge/carapace.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"github.com/rsteube/carapace/pkg/xdg"
)

// ActionCarapace bridges rsteube/carapace completion
// ActionCarapace bridges https://github.com/rsteube/carapace
func ActionCarapace(cmd string) carapace.Action {
return carapace.ActionCallback(func(c carapace.Context) carapace.Action {
args := []string{"_carapace", "export", ""}
Expand All @@ -24,7 +24,7 @@ func ActionCarapace(cmd string) carapace.Action {
})
}

// ActionCarapaceBin bridges a completer provided by carapace-bin
// ActionCarapaceBin bridges completions registered in carapace-bin
func ActionCarapaceBin(completer string) carapace.Action {
return carapace.ActionCallback(func(c carapace.Context) carapace.Action {
if a, err := actionSpec(completer); err == nil {
Expand Down
2 changes: 1 addition & 1 deletion pkg/actions/bridge/cobra.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"github.com/spf13/cobra"
)

// ActionCobra bridges cobra completion
// ActionCobra bridges https://github.com/spf13/cobra
//
// var rootCmd = &cobra.Command{
// Use: "podman",
Expand Down
2 changes: 1 addition & 1 deletion pkg/actions/bridge/complete.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"github.com/rsteube/carapace"
)

// ActionComplete bridges posener/complete
// ActionComplete bridges https://github.com/posener/complete
//
// var rootCmd = &cobra.Command{
// Use: "vault",
Expand Down
11 changes: 0 additions & 11 deletions pkg/actions/bridge/posener.go

This file was deleted.