diff --git a/docs/diff.rst b/docs/diff.rst index 513d08e..4d50ed8 100644 --- a/docs/diff.rst +++ b/docs/diff.rst @@ -17,6 +17,12 @@ A diff shows the changes between trees, an index or the working dir:: # Diff a tree with the current working dir >>> diff = head.tree.diff() + # Get all patches for a diff + >>> t0 = repo.revparse_single('HEAD^').tree + >>> t1 = repo.revparse_single('HEAD~3').tree + >>> diff = t0.diff(t1) + >>> patches = [p for p in diff] + The Diff type ==================== diff --git a/src/diff.c b/src/diff.c index d7c2b69..aa69ee2 100644 --- a/src/diff.c +++ b/src/diff.c @@ -227,7 +227,7 @@ PyTypeObject DiffIterType = { }; -PyDoc_STRVAR(Diff_patch__doc__, "Patch."); +PyDoc_STRVAR(Diff_patch__doc__, "Patch diff string."); PyObject * Diff_patch__get__(Diff *self)