Merge pull request #5892 from thaJeztah/pluginmanager_smaller_interface

cli-plugins/manager: use shallower interface
This commit is contained in:
Sebastiaan van Stijn
2025-03-05 13:18:57 +01:00
committed by GitHub
5 changed files with 33 additions and 22 deletions
+1 -1
View File
@@ -46,7 +46,7 @@ type Cli interface {
Streams
SetIn(in *streams.In)
Apply(ops ...CLIOption) error
ConfigFile() *configfile.ConfigFile
config.Provider
ServerInfo() ServerInfo
DefaultVersion() string
CurrentVersion() string
+5
View File
@@ -69,6 +69,11 @@ func getHomeDir() string {
return home
}
// Provider defines an interface for providing the CLI config.
type Provider interface {
ConfigFile() *configfile.ConfigFile
}
// Dir returns the directory the configuration file is stored in
func Dir() string {
initConfigDir.Do(func() {