github.com/franc20/ayesa_sap@v7.0.0-beta.28.0.20200124003224-302d4d52fa6c+incompatible/command/translatableerror/plugin_already_installed_error.go (about) 1 package translatableerror 2 3 // PluginAlreadyInstalledError is returned when the plugin has the same name as 4 // an installed plugin. 5 type PluginAlreadyInstalledError struct { 6 BinaryName string 7 Name string 8 Version string 9 } 10 11 func (PluginAlreadyInstalledError) Error() string { 12 return "Plugin {{.Name}} {{.Version}} could not be installed. A plugin with that name is already installed.\nTIP: Use '{{.BinaryName}} install-plugin -f' to force a reinstall." 13 } 14 15 func (e PluginAlreadyInstalledError) Translate(translate func(string, ...interface{}) string) string { 16 return translate(e.Error(), map[string]interface{}{ 17 "BinaryName": e.BinaryName, 18 "Name": e.Name, 19 "Version": e.Version, 20 }) 21 }