MCPcopy Create free account
hub / github.com/cloudquery/cloudquery / normalizePluginPath

Function normalizePluginPath

cli/cmd/init.go:90–99  ·  view source on GitHub ↗
(pluginNameOrPath string)

Source from the content-addressed store, hash-verified

88}
89
90func normalizePluginPath(pluginNameOrPath string) (string, error) {
91 parts := strings.Split(pluginNameOrPath, "/")
92 if len(parts) == 1 {
93 return "cloudquery/" + pluginNameOrPath, nil
94 }
95 if len(parts) != 2 {
96 return "", errors.New("invalid plugin path")
97 }
98 return pluginNameOrPath, nil
99}
100
101func parseFlags(cmd *cobra.Command) (source, destination, specPath string, acceptDefaults, disableAI, resumeConversation, disablePlatform bool, allErrors error) {
102 source, err := cmd.Flags().GetString("source")

Callers 2

parseFlagsFunction · 0.85
initCmdFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected