Allow file annotations (blame) in side-by-side diff

Using CodeMirror's lint addon on the UI to display the blame
annotations. It works on both sides of the side-by-side
diff and also supports the auto-merge commit. It requires manual
step to enable the annotations to avoid any unnecessary git
processing and network traffic between the server and client.

Introduces a new dependency on blame-cache in gerrit-server
to reuse BlameCache.

In a following change, the gutter showing the blame info will be
made clickable. Clicking on the gutter will open a new tab that
takes the user to the corresponding change in Gerrit.

The commit SHA-1 hashes are currently not selectable. Making it
so might require an upstream change in CodeMirror's lint addon.

Bug: Issue 1642
Change-Id: I6267d30cbee448f8137e11c7120959dc424eaeeb
This commit is contained in:
Gabor Somossy
2015-10-20 23:40:07 +01:00
committed by Michael Zhou
parent b3ba766ffa
commit b72d4c6d8f
27 changed files with 655 additions and 0 deletions

View File

@@ -3,6 +3,7 @@ CM_CSS = [
'addon/dialog/dialog.css',
'addon/scroll/simplescrollbars.css',
'addon/search/matchesonscrollbar.css',
'addon/lint/lint.css',
]
CM_JS = [
@@ -28,6 +29,7 @@ CM_ADDONS = [
'mode/multiplex.js',
'mode/overlay.js',
'mode/simple.js',
'lint/lint.js',
]
# Available themes must be enumerated here,