mirror of
https://github.com/JanDeDobbeleer/oh-my-posh.git
synced 2024-11-10 04:54:03 -08:00
chore: do not auto migrate on manual switch
This commit is contained in:
parent
6fcae4207e
commit
bfca351796
|
@ -75,7 +75,8 @@ func (cfg *Config) exitWithError(err error) {
|
|||
// LoadConfig returns the default configuration including possible user overrides
|
||||
func LoadConfig(env environment.Environment) *Config {
|
||||
cfg := loadConfig(env)
|
||||
if cfg.Version != configVersion {
|
||||
// only migrate automatically when the switch isn't set
|
||||
if !*env.Args().Migrate && cfg.Version != configVersion {
|
||||
cfg.Backup()
|
||||
cfg.Migrate(env)
|
||||
cfg.Write()
|
||||
|
|
Loading…
Reference in a new issue