parent
b932b76c8b
commit
38d88eecbb
|
@ -98,6 +98,24 @@ class CvsStatus(Method):
|
|||
wrev, rrev, stag,
|
||||
sdate, soptions))
|
||||
|
||||
class CvsLog(Method):
|
||||
'''diff the current file with the version in CVS'''
|
||||
def _execute(self, w, **vargs):
|
||||
if not hasattr(w.buffer, 'path'):
|
||||
w.set_error("Buffer has no corresponding file")
|
||||
return
|
||||
|
||||
cwd = os.getcwd() + os.path.sep
|
||||
path = w.buffer.path
|
||||
if path.startswith(cwd):
|
||||
path = path[len(cwd):]
|
||||
|
||||
cmd = "cvs log %r" % path
|
||||
(status, data) = commands.getstatusoutput(cmd)
|
||||
status = status >> 8
|
||||
w.application.data_buffer("*Log*", data, switch_to=True)
|
||||
w.set_error("cvs log exited with %d" % status)
|
||||
|
||||
class CvsDiff(Method):
|
||||
'''diff the current file with the version in CVS'''
|
||||
def _execute(self, w, **vargs):
|
||||
|
|
Loading…
Reference in New Issue