From 9a49ec0dcd6f75736949350844f85d80fe48a662 Mon Sep 17 00:00:00 2001 From: Alexander Foremny Date: Thu, 29 Feb 2024 04:11:10 +0100 Subject: wip: add `review` command Prototype of the `review` command, cf. `anissue review -h`. Also adds the `status` command. --- app/Git/CommitHash.hs | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'app/Git/CommitHash.hs') diff --git a/app/Git/CommitHash.hs b/app/Git/CommitHash.hs index db7a478..0caecf4 100644 --- a/app/Git/CommitHash.hs +++ b/app/Git/CommitHash.hs @@ -2,6 +2,7 @@ module Git.CommitHash ( CommitHash (..), toShortText, toText, + toTextUnsafe, ) where @@ -23,6 +24,10 @@ toText :: CommitHash -> Maybe T.Text toText WorkingTree = Nothing toText (Commit hash) = Just hash +toTextUnsafe :: CommitHash -> T.Text +toTextUnsafe (Commit hash) = hash +toTextUnsafe _ = error "toTextUnsafe: WorkingDir" + instance P.Render CommitHash where render = P.render . P.Detailed -- cgit v1.2.3