func constructPluginInstallJSONURL(plugin string) (string, installResult) { installJSONFile := plugin + "-install.json" repoURL := config.GaugeRepositoryUrl() if repoURL == "" { return "", installError("Could not find gauge repository url from configuration.") } return fmt.Sprintf("%s/%s", repoURL, installJSONFile), installSuccess("") }
func constructPluginInstallJSONURL(p string) (string, InstallResult) { repoURL := config.GaugeRepositoryUrl() if repoURL == "" { return "", installError(fmt.Errorf("Could not find gauge repository url from configuration.")) } JSONURL := fmt.Sprintf("%s/%s", repoURL, p) if qp := plugin.QueryParams(); qp != "" { JSONURL += qp } return JSONURL, installSuccess("") }