Mercurial > hg
changeset 24371:8a997bd73448
patch.trydiff: add a docstring
It took me a bit to figure out what this function actually does.
author | Siddharth Agarwal <sid0@fb.com> |
---|---|
date | Tue, 17 Mar 2015 13:06:15 -0700 |
parents | 3e8b06097d00 |
children | 577f65cf1a57 |
files | mercurial/patch.py |
diffstat | 1 files changed, 6 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/patch.py Tue Mar 17 15:33:34 2015 -0700 +++ b/mercurial/patch.py Tue Mar 17 13:06:15 2015 -0700 @@ -2226,6 +2226,12 @@ def trydiff(repo, revs, ctx1, ctx2, modified, added, removed, copy, getfilectx, opts, losedatafn, prefix): + '''given input data, generate a diff and yield it in blocks + + If generating a diff would lose data like flags or binary data and + losedatafn is not None, it will be called. + + prefix is added to every path in the diff output.''' def gitindex(text): if not text: