diff options
Diffstat (limited to 'app/Issue.hs')
-rw-r--r-- | app/Issue.hs | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/app/Issue.hs b/app/Issue.hs index 72fbad3..0d9f6ad 100644 --- a/app/Issue.hs +++ b/app/Issue.hs @@ -32,7 +32,7 @@ fromMatch result match = Just Issue { title = stripMarker (T.strip (T.unlines title)), - description = T.strip (T.unlines description), + description = stripTags (T.strip (T.unlines description)), start = match.start, end = match.end, tags = I.extract text @@ -48,6 +48,10 @@ fromMatch result match = marker :: Text marker = "TODO" +stripTags :: Text -> Text +stripTags text = + T.strip (T.unlines (filter (not . T.isPrefixOf "@") (T.lines text))) + stripMarker :: Text -> Text stripMarker text = maybe text T.stripStart (T.stripPrefix marker text) |