New command: do_log(page).

This new command displays the last revisions of the page.

TODO: specific formatter (it should display the history like git log).
This commit is contained in:
Clément Schreiner 2011-02-16 22:25:30 +01:00
commit a6f5ef2049

View file

@ -113,3 +113,11 @@ class WebContentEdit(ReplApplication):
if len(errors.errors) > 0:
raise errors
def do_log(self, line):
for id in line.split():
_id, backend_name = self.parse_id(id)
backend_names = (backend_name,) if backend_name is not None else self.enabled_backends
for backend, revision in self.do('iter_revisions', _id):
self.format(revision)