internal/outcome/process: output via msg
All checks were successful
Test / Create distribution (push) Successful in 33s
Test / Sandbox (push) Successful in 2m13s
Test / Hakurei (push) Successful in 3m9s
Test / Hpkg (push) Successful in 3m57s
Test / Sandbox (race detector) (push) Successful in 4m8s
Test / Hakurei (race detector) (push) Successful in 4m54s
Test / Flake checks (push) Successful in 1m27s

This makes it possible to instrument output behaviour through stub.

Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
2025-10-30 03:34:24 +09:00
parent eeb9f98e5b
commit 36f8064905
3 changed files with 20 additions and 13 deletions

View File

@@ -3,7 +3,6 @@ package outcome
import (
"context"
"log"
"os"
"hakurei.app/hst"
"hakurei.app/message"
@@ -18,8 +17,8 @@ func Main(ctx context.Context, msg message.Msg, config *hst.Config) {
seal := outcome{syscallDispatcher: direct{msg}}
if err := seal.finalise(ctx, msg, &id, config); err != nil {
printMessageError("cannot seal app:", err)
os.Exit(1)
printMessageError(msg.GetLogger().Fatalln, "cannot seal app:", err)
panic("unreachable")
}
seal.main(msg)