From c5c11ed1815990881c7f46691e4e181040a3c7d5 Mon Sep 17 00:00:00 2001 From: Paul Brinkmeier Date: Tue, 7 Oct 2025 12:53:14 +0200 Subject: [PATCH] Don't buffer stdout --- app/Main.hs | 3 +++ yore.cabal | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/app/Main.hs b/app/Main.hs index b0c716a..343eed6 100644 --- a/app/Main.hs +++ b/app/Main.hs @@ -65,6 +65,7 @@ import Data.Time.Clock.POSIX (getPOSIXTime) import qualified Envy import qualified Yore.DB as DB import qualified Yore.Log as Log +import System.IO (hSetBuffering, BufferMode (..), stdout) data ConfigT f = Config { yorePort :: f =@@ Int ? 3000 @@ -79,6 +80,8 @@ deriving instance Show Config main :: IO () main = do + hSetBuffering stdout NoBuffering + cfg <- Envy.load @ConfigT >>= \case Left errs -> do diff --git a/yore.cabal b/yore.cabal index 340a4f6..a78821a 100644 --- a/yore.cabal +++ b/yore.cabal @@ -1,7 +1,7 @@ cabal-version: 3.4 name: yore -version: 0.0.2 +version: 0.0.3 author: Paul Brinkmeier maintainer: hallo@pbrinkmeier.de copyright: 2023 Paul Brinkmeier