# HG changeset patch # User Yuya Nishihara # Date 1542533731 -32400 # Node ID 698477777883174cb8ab3b0977ea2e5368160652 # Parent 03127e5809806c718719e9547dc9fd952e7bbe5d loggingutil: document openlogfile() This function will be used later for command-server logging. diff -r 03127e580980 -r 698477777883 mercurial/loggingutil.py --- a/mercurial/loggingutil.py Sun Nov 18 18:25:37 2018 +0900 +++ b/mercurial/loggingutil.py Sun Nov 18 18:35:31 2018 +0900 @@ -15,6 +15,10 @@ ) def openlogfile(ui, vfs, name, maxfiles=0, maxsize=0): + """Open log file in append mode, with optional rotation + + If maxsize > 0, the log file will be rotated up to maxfiles. + """ def rotate(oldpath, newpath): try: vfs.unlink(newpath)