aboutsummaryrefslogtreecommitdiffstats
path: root/app/Issue.hs
diff options
context:
space:
mode:
authorLibravatar Alexander Foremny <aforemny@posteo.de>2023-11-30 03:49:39 +0100
committerLibravatar Alexander Foremny <aforemny@posteo.de>2023-11-30 03:49:41 +0100
commit650d139254a0e17be0b1011f2fda6ea67f903e71 (patch)
treeebfcd8606da922c536cb6414cfa816d2aa65c17f /app/Issue.hs
parentff5535f0a55201c6883c48c3892c9ef357904356 (diff)
feat: support closed issues
Closed issues can be shown, but listing closed issues requires passing `--closed`.
Diffstat (limited to 'app/Issue.hs')
-rw-r--r--app/Issue.hs6
1 files changed, 4 insertions, 2 deletions
diff --git a/app/Issue.hs b/app/Issue.hs
index f0940f2..bcb5333 100644
--- a/app/Issue.hs
+++ b/app/Issue.hs
@@ -31,7 +31,8 @@ data Issue = Issue
markers :: [T.Text],
rawText :: T.Text,
commentStyle :: G.CommentStyle,
- comments :: [T.Text]
+ comments :: [T.Text],
+ closed :: Bool
}
deriving (Show, Binary, Generic, Eq)
@@ -48,7 +49,8 @@ internalTags (Issue {..}) =
Tag "createdAt" $ Just $ T.pack $ show $ utctDay provenance.first.date,
Tag "modifiedAt" $ Just $ T.pack $ show $ utctDay provenance.last.date,
Tag "author" $ Just $ provenance.first.author.name,
- Tag "editor" $ Just $ provenance.last.author.name
+ Tag "editor" $ Just $ provenance.last.author.name,
+ Tag "state" $ Just $ if closed then "closed" else "open"
],
map (Tag "type" . Just) markers
]