parent
b2c036479f
commit
6e02ce8b4d
|
@ -4,7 +4,7 @@ from subprocess import Popen, PIPE, STDOUT
|
|||
import buffer, default, dirutil, lex, regex, util, window
|
||||
from point import Point
|
||||
import buffer.colors
|
||||
from method.vc import VcBlame, VcRevView, VcBase
|
||||
from method.vc import VcBlame, VcRevView, VcBase, VcException
|
||||
|
||||
from method import Method, Argument, arg
|
||||
|
||||
|
@ -176,7 +176,7 @@ class GitBlame(VcBlame):
|
|||
'''show blame output for the current version in SVN'''
|
||||
# rev, user, date, [time], [timezone], [date-str], content
|
||||
num_fields = 3
|
||||
line_re = re.compile(r'^([0-9a-f]+) \(([a-zA-Z0-9_]+|Not Committed Yet) +([-0-9]+) [:0-9]+ +[-\+]\d{4} +\d+\) (.*)\n$')
|
||||
line_re = re.compile(r'^\^*([0-9a-f]+) \(([a-zA-Z0-9_]+|Not Committed Yet) +([-0-9]+) [:0-9]+ +[-\+]\d{4} +\d+\) (.*)\n$')
|
||||
prefix_fmt = '[g:d:*]%*s [c:d:*]%-*s [b:d:*]%*s[d:d:*]'
|
||||
pretest_err_msg = 'Git is not installed'
|
||||
_is_method = True
|
||||
|
@ -188,6 +188,8 @@ class GitBlame(VcBlame):
|
|||
fields = list(groups[:-1])
|
||||
if fields[1] == 'Not Committed Yet':
|
||||
fields[1] = ''
|
||||
if fields[0] == '00000000':
|
||||
fields[0] = ''
|
||||
return {'fields': fields, 'content': groups[-1], 'tokens': []}
|
||||
def _pretest(self):
|
||||
return has_git
|
||||
|
|
Loading…
Reference in New Issue