#8 add default.

This commit is contained in:
Gorbunov Kirill Andreevich 2024-04-02 17:21:55 +03:00
parent 89c081a1fb
commit 284496213c

View File

@ -143,8 +143,6 @@ func main() {
} }
} }
logger.Info(ctx, fmt.Sprintf("Load config... %s", cfg.Source.Repository))
if cfg.PullRequestBody == "" { if cfg.PullRequestBody == "" {
cfg.PullRequestBody = DefaultPullRequestBody cfg.PullRequestBody = DefaultPullRequestBody
} }
@ -225,9 +223,6 @@ func main() {
logger.Error(ctx, err.Error()) logger.Error(ctx, err.Error())
} }
logger.Debugf(ctx, fmt.Sprintf("cfg: %v", cfg))
logger.Debugf(ctx, fmt.Sprintf("cfg cli: %s", cliCfg))
gitSource := source.NewSourceControl(*cfg) gitSource := source.NewSourceControl(*cfg)
Execute(ctx, gitSource, mvs, *cliCfg, *cfg) Execute(ctx, gitSource, mvs, *cliCfg, *cfg)
@ -309,6 +304,8 @@ func Execute(ctx context.Context, gitSource source.SourceControl, mvs map[string
prList[branch] = rMap prList[branch] = rMap
} }
logger.Info(ctx, fmt.Sprintf("for %s:\n%s", cfg.Source.Repository, prList)) logger.Info(ctx, fmt.Sprintf("for %s:\n%s", cfg.Source.Repository, prList))
default:
logger.Info(ctx, initMsg)
} }
} }