diff --git a/src/Vervis/Darcs.hs b/src/Vervis/Darcs.hs index 17e5a50..9d1fc45 100644 --- a/src/Vervis/Darcs.hs +++ b/src/Vervis/Darcs.hs @@ -302,8 +302,8 @@ readPatch path hash = do Right mi -> loop pih (miPatches mi) (Just $ miPrevious mi) email = maybe (fail "invalid email") pure . emailAddress . encodeUtf8 author = (,) - <$> A.takeWhile1 (const True) - <* " <" + <$> (T.stripEnd <$> A.takeWhile1 (/= '<')) + <* A.skip (== '<') <*> (A.takeWhile1 (/= '>') >>= email) <* A.skip (== '>') mkedit (file, hunks) =