Mercurial > hg
comparison hgext/largefiles/overrides.py @ 27655:af13eaf9ab8c
merge: add a new 'backup' argument to get actions
We're going to use this in an upcoming patch to back untracked files up when
they're replaced by tracked ones.
author | Siddharth Agarwal <sid0@fb.com> |
---|---|
date | Sat, 02 Jan 2016 03:02:57 -0800 |
parents | 42910f9fffeb |
children | 00bd72629a45 |
comparison
equal
deleted
inserted
replaced
27654:95dc67f10239 | 27655:af13eaf9ab8c |
---|---|
481 (lm, largs, lmsg) = actions.get(lfile, (None, None, None)) | 481 (lm, largs, lmsg) = actions.get(lfile, (None, None, None)) |
482 (sm, sargs, smsg) = actions.get(standin, (None, None, None)) | 482 (sm, sargs, smsg) = actions.get(standin, (None, None, None)) |
483 if sm in ('g', 'dc') and lm != 'r': | 483 if sm in ('g', 'dc') and lm != 'r': |
484 if sm == 'dc': | 484 if sm == 'dc': |
485 f1, f2, fa, move, anc = sargs | 485 f1, f2, fa, move, anc = sargs |
486 sargs = (p2[f2].flags(),) | 486 sargs = (p2[f2].flags(), False) |
487 # Case 1: normal file in the working copy, largefile in | 487 # Case 1: normal file in the working copy, largefile in |
488 # the second parent | 488 # the second parent |
489 usermsg = _('remote turned local normal file %s into a largefile\n' | 489 usermsg = _('remote turned local normal file %s into a largefile\n' |
490 'use (l)argefile or keep (n)ormal file?' | 490 'use (l)argefile or keep (n)ormal file?' |
491 '$$ &Largefile $$ &Normal file') % lfile | 491 '$$ &Largefile $$ &Normal file') % lfile |
499 else: | 499 else: |
500 actions[standin] = ('r', None, 'replaced by non-standin') | 500 actions[standin] = ('r', None, 'replaced by non-standin') |
501 elif lm in ('g', 'dc') and sm != 'r': | 501 elif lm in ('g', 'dc') and sm != 'r': |
502 if lm == 'dc': | 502 if lm == 'dc': |
503 f1, f2, fa, move, anc = largs | 503 f1, f2, fa, move, anc = largs |
504 largs = (p2[f2].flags(),) | 504 largs = (p2[f2].flags(), False) |
505 # Case 2: largefile in the working copy, normal file in | 505 # Case 2: largefile in the working copy, normal file in |
506 # the second parent | 506 # the second parent |
507 usermsg = _('remote turned local largefile %s into a normal file\n' | 507 usermsg = _('remote turned local largefile %s into a normal file\n' |
508 'keep (l)argefile or use (n)ormal file?' | 508 'keep (l)argefile or use (n)ormal file?' |
509 '$$ &Largefile $$ &Normal file') % lfile | 509 '$$ &Largefile $$ &Normal file') % lfile |