5f0729f155
When running git blame in a "git show" buffer, we annotate the youngest version of the file that has the line referenced by the diff line at cursor. In case the cursor is on an added or context line, we simply show the version from the surrounding commit. When the cursor is on a deleted line, we show the parent commit, which still has the deleted line. However there is a bug: we use the line number in the new version of the file. Fix that.
12 lines
402 B
Plaintext
12 lines
402 B
Plaintext
ui_out -ignore 7
|
|
ui_out -ignore 11
|
|
|
|
# We've jumped to the new version of line 2. Move to the old version so we
|
|
# can annotate the old file.
|
|
ui_in '{ "jsonrpc": "2.0", "method": "keys", "params": [ "k:git blame<ret>" ] }'
|
|
ui_out -ignore 11
|
|
|
|
# We should have jumped to the old version of line 2, assert on kak_selection.
|
|
ui_in '{ "jsonrpc": "2.0", "method": "keys", "params": [ "x" ] }'
|
|
ui_out -ignore 5
|