Highlighting differences of lines in the diff view.

This commit is contained in:
Andrey Nering 2016-01-03 19:26:46 -02:00
parent 0cb7396840
commit 73474c043b
6 changed files with 137 additions and 3 deletions

View file

@ -168,6 +168,12 @@ func Diff(ctx *middleware.Context) {
}
}
for _, diffFile := range diff.Files {
for _, diffSection := range diffFile.Sections {
diffSection.ComputeLinesDiff()
}
}
ctx.Data["IsSplitStyle"] = ctx.Query("style") == "split"
ctx.Data["Username"] = userName
ctx.Data["Reponame"] = repoName