1
1
mirror of https://github.com/github/semantic.git synced 2024-12-26 08:25:19 +03:00

add some dots

This commit is contained in:
joshvera 2016-02-10 10:57:41 -08:00
parent a812b41c27
commit 44578211ff

View File

@ -70,7 +70,7 @@ getRange (Pure (Info range _ :< _)) = range
header :: (SourceBlob, SourceBlob) -> Hunk a -> String
header blobs hunk = "diff --git a/path.txt b/path.txt\n" ++
"index " ++ oid (fst blobs) ++ " " ++ oid (snd blobs) ++ "\n" ++
"index " ++ oid (fst blobs) ++ ".." ++ oid (snd blobs) ++ "\n" ++
"@@ -" ++ show offsetA ++ "," ++ show lengthA ++ " +" ++ show offsetB ++ "," ++ show lengthB ++ " @@\n"
where (lengthA, lengthB) = join bimap getSum $ hunkLength hunk
(offsetA, offsetB) = join bimap getSum $ offset hunk