From 0ae2a8ebbc88e013d2a79ee727da82931002ef96 Mon Sep 17 00:00:00 2001 From: Alexander Foremny Date: Mon, 12 Feb 2024 04:33:06 +0100 Subject: `FilePath` -> `Collection` --- app/Main.hs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/Main.hs b/app/Main.hs index 3cb3b79..3b630ac 100644 --- a/app/Main.hs +++ b/app/Main.hs @@ -112,7 +112,7 @@ data FieldSelector deriving (Show) data Field - = Qualified FilePath T.Text + = Qualified Collection T.Text | Unqualified T.Text deriving (Show) @@ -147,7 +147,7 @@ data Comparison deriving (Show) data Record a - = Record FilePath a + = Record Collection a deriving (Show, Eq) data ParseError = ParseError String @@ -356,7 +356,7 @@ data DecodeException = DecodeException instance Exception DecodeException -decodeFile :: J.FromJSON a => FilePath -> IO a +decodeFile :: J.FromJSON a => Collection -> IO a decodeFile fp = S.withStore "." "HEAD" do fromMaybe (throw DecodeException) . J.decode <$> S.readFile fp -- cgit v1.2.3