From 310ece7f2de4a6e20cb149d623b06ebe8db35d33 Mon Sep 17 00:00:00 2001 From: Filip Gralinski Date: Tue, 11 Dec 2018 13:25:19 +0100 Subject: [PATCH] Get rid of f**king Windows end-of-line characters I hate it so much. Die, die, stupid \r --- src/GEval/Core.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/GEval/Core.hs b/src/GEval/Core.hs index a807a08..855e187 100644 --- a/src/GEval/Core.hs +++ b/src/GEval/Core.hs @@ -446,7 +446,7 @@ getInputSourceIfNeeded forced metrics directory inputFilePath fileAsLineSource :: SourceSpec -> (Text -> Text) -> LineSource (ResourceT IO) fileAsLineSource spec preprocess = - LineSource ((smartSource spec) .| autoDecompress .| CT.decodeUtf8Lenient .| CT.lines) preprocess spec 1 + LineSource ((smartSource spec) .| autoDecompress .| CT.decodeUtf8Lenient .| CT.lines .| CC.map (dropAround (== '\r'))) preprocess spec 1 gevalCoreOnSingleLines :: Metric -> (Text -> Text) -> LineInFile -> LineInFile -> LineInFile -> IO (MetricValue) gevalCoreOnSingleLines metric preprocess inpLine expLine outLine =