refactor: move defaultConfig from config_legacy to config
This commit is contained in:
parent
91937a1fc5
commit
eeb25c239b
@ -37,6 +37,18 @@ type ALRConfig struct {
|
|||||||
pathsOnce sync.Once
|
pathsOnce sync.Once
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var defaultConfig = &types.Config{
|
||||||
|
RootCmd: "sudo",
|
||||||
|
PagerStyle: "native",
|
||||||
|
IgnorePkgUpdates: []string{},
|
||||||
|
Repos: []types.Repo{
|
||||||
|
{
|
||||||
|
Name: "default",
|
||||||
|
URL: "https://gitea.plemya-x.ru/xpamych/xpamych-alr-repo.git",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
func New() *ALRConfig {
|
func New() *ALRConfig {
|
||||||
return &ALRConfig{}
|
return &ALRConfig{}
|
||||||
}
|
}
|
||||||
|
@ -25,18 +25,6 @@ import (
|
|||||||
"plemya-x.ru/alr/internal/types"
|
"plemya-x.ru/alr/internal/types"
|
||||||
)
|
)
|
||||||
|
|
||||||
var defaultConfig = &types.Config{
|
|
||||||
RootCmd: "sudo",
|
|
||||||
PagerStyle: "native",
|
|
||||||
IgnorePkgUpdates: []string{},
|
|
||||||
Repos: []types.Repo{
|
|
||||||
{
|
|
||||||
Name: "default",
|
|
||||||
URL: "https://gitea.plemya-x.ru/xpamych/xpamych-alr-repo.git",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
// Config returns a ALR configuration struct.
|
// Config returns a ALR configuration struct.
|
||||||
// The first time it's called, it'll load the config from a file.
|
// The first time it's called, it'll load the config from a file.
|
||||||
// Subsequent calls will just return the same value.
|
// Subsequent calls will just return the same value.
|
||||||
|
Loading…
Reference in New Issue
Block a user