File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed
completers/common/aws_completer/cmd Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change 11package cmd
22
33import (
4+ "os/exec"
45 "strings"
56
67 "github.com/carapace-sh/carapace"
8+ "github.com/carapace-sh/carapace-bridge/pkg/actions/bridge"
79 "github.com/carapace-sh/carapace/pkg/style"
810 "github.com/spf13/cobra"
911)
@@ -25,6 +27,10 @@ func init() {
2527
2628 carapace .Gen (rootCmd ).PositionalAnyCompletion (
2729 carapace .ActionCallback (func (c carapace.Context ) carapace.Action {
30+ if _ , err := exec .LookPath ("carapace-aws" ); err == nil {
31+ return bridge .ActionCarapace ("carapace-aws" )
32+ }
33+
2834 if c .Value == "-" {
2935 c .Value += "-" // no shorthand flags so expand to longhand first (which is needed for the completer)
3036 }
You can’t perform that action at this time.
0 commit comments