Skip to content

Commit d6d0fde

Browse files
committed
pkg/mgrconfig: export defaultValues function
It may be useful if the config value is synthesised programmatically.
1 parent edf0160 commit d6d0fde

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

pkg/mgrconfig/load.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ func LoadFile(filename string) (*Config, error) {
6969
}
7070

7171
func LoadPartialData(data []byte) (*Config, error) {
72-
cfg := defaultValues()
72+
cfg := DefaultValues()
7373
if err := config.LoadData(data, cfg); err != nil {
7474
return nil, err
7575
}
@@ -80,7 +80,7 @@ func LoadPartialData(data []byte) (*Config, error) {
8080
}
8181

8282
func LoadPartialFile(filename string) (*Config, error) {
83-
cfg := defaultValues()
83+
cfg := DefaultValues()
8484
if err := config.LoadFile(filename, cfg); err != nil {
8585
return nil, err
8686
}
@@ -90,7 +90,7 @@ func LoadPartialFile(filename string) (*Config, error) {
9090
return cfg, nil
9191
}
9292

93-
func defaultValues() *Config {
93+
func DefaultValues() *Config {
9494
return &Config{
9595
SSHUser: "root",
9696
Cover: true,

0 commit comments

Comments
 (0)