diff options
Diffstat (limited to 'app/Main.hs')
-rw-r--r-- | app/Main.hs | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/app/Main.hs b/app/Main.hs index 334f3ce..5793363 100644 --- a/app/Main.hs +++ b/app/Main.hs @@ -88,7 +88,7 @@ import Options.Applicative ((<**>)) import Options.Applicative qualified as O import Prettyprinter qualified as P import Prettyprinter.Render.Terminal qualified as P -import Process (sh, sh_, quote) +import Process (quote, sh, sh_) import System.Exit (ExitCode (ExitFailure), exitWith) import System.FilePath qualified as F import System.Process.Typed qualified as P @@ -178,8 +178,7 @@ main = do ( \issue -> P.hsep ( concat - [ [P.pretty issue.provenance.firstCommit, P.pretty (" " :: String)], - [P.annotate P.bold (P.pretty issue.title)], + [ [P.annotate P.bold (P.pretty issue.title)], map ( \(I.Tag k v) -> P.annotate (P.colorDull P.Yellow) $ @@ -203,6 +202,19 @@ main = do issue.file ++ ":" ++ show issue.start.row + ++ ( case issue.provenance of + Nothing -> + "HEAD" + Just provenance -> + "\nvia " + ++ T.unpack provenance.firstCommit + ++ "\nby " + ++ T.unpack provenance.authorName + ++ " <" + ++ T.unpack provenance.authorEmail + ++ ">\nat " + ++ show provenance.date + ) ++ "\n\n" sh_ ( P.setStdin |