comparison mercurial/copies.py @ 40058:cf01616f8d96

copies: add time information to the debug information
author Boris Feld <boris.feld@octobus.net>
date Fri, 07 Sep 2018 11:43:48 -0400
parents 25b2868206e2
children 2e9378f62232
comparison
equal deleted inserted replaced
40057:25b2868206e2 40058:cf01616f8d96
202 if debug: 202 if debug:
203 dbg('debug.copies: tracing file: %s\n' % f) 203 dbg('debug.copies: tracing file: %s\n' % f)
204 fctx = b[f] 204 fctx = b[f]
205 fctx._ancestrycontext = ancestrycontext 205 fctx._ancestrycontext = ancestrycontext
206 206
207 if debug:
208 start = util.timer()
207 ofctx = _tracefile(fctx, am, limit) 209 ofctx = _tracefile(fctx, am, limit)
208 if ofctx: 210 if ofctx:
209 if debug: 211 if debug:
210 dbg('debug.copies: rename of: %s\n' % ofctx._path) 212 dbg('debug.copies: rename of: %s\n' % ofctx._path)
211 cm[f] = ofctx.path() 213 cm[f] = ofctx.path()
214 if debug:
215 dbg('debug.copies: time: %s seconds\n'
216 % (util.timer() - start))
212 return cm 217 return cm
213 218
214 def _forwardcopies(a, b, match=None): 219 def _forwardcopies(a, b, match=None):
215 """find {dst@b: src@a} copy mapping where a is an ancestor of b""" 220 """find {dst@b: src@a} copy mapping where a is an ancestor of b"""
216 221