summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Biz/Devalloc.hs16
1 files changed, 8 insertions, 8 deletions
diff --git a/Biz/Devalloc.hs b/Biz/Devalloc.hs
index 7112020..32fa7f9 100644
--- a/Biz/Devalloc.hs
+++ b/Biz/Devalloc.hs
@@ -1746,8 +1746,8 @@ lastTouched bareRepo path = do
where
calculateAge now n = round <| Time.diffUTCTime now n / Time.nominalDay
--- | Given a git dir and a path inside the git repo, return a list of tuples
--- with number of commits and author.
+-- | Given a git dir and a path inside the git repo, get information about the
+-- authors.
authorsFor ::
FilePath ->
FilePath ->
@@ -1770,12 +1770,12 @@ authorsFor gitDir path =
/> Text.pack
/> Text.lines
/> map (Text.break (== '\t'))
- /> map
- ( \(commits, author) ->
- ( Text.strip commits,
- Text.strip <| Text.takeWhile (/= '<') author,
- Text.strip <| Text.dropAround (`elem` ['<', '>']) <| Text.dropWhile (/= '<') author
- )
+ /> map parseAuthor
+ where
+ parseAuthor (commits, author) =
+ ( Text.strip commits,
+ Text.strip <| Text.takeWhile (/= '<') author,
+ Text.strip <| Text.dropAround (`elem` ['<', '>']) <| Text.dropWhile (/= '<') author
)
spliceCreds :: User -> Text -> Text