make application with base logic

This commit is contained in:
Gitea
2023-11-26 15:39:34 +03:00
parent 0553ea71c3
commit 606b94e35b
32 changed files with 1070 additions and 27 deletions

View File

@ -44,10 +44,15 @@ func setupCLI(ctx context.Context) cli.App {
log := makeLogger(options)
client, err := makeSravniClient(ctx, log, options)
if err != nil {
log.ErrorContext(ctx, "making client", slog.Any("err", err))
log.ErrorContext(ctx, "unable to make client", slog.Any("err", err))
return -1
}
state, err := client.GetMainPageState()
if err != nil {
log.ErrorContext(ctx, "unable to make page state", slog.Any("err", err))
return -1
}
state := client.GetMainPageState()
var out any
switch options["part"] {