##// END OF EJS Templates
record: access status fields by name rather than index...
Martin von Zweigbergk -
r22921:75e7d4a0 default
parent child Browse files
Show More
@@ -519,12 +519,12 b' def dorecord(ui, repo, commitfunc, cmdsu'
519 519 raise util.Abort(_('cannot partially commit a merge '
520 520 '(use "hg commit" instead)'))
521 521
522 changes = repo.status(match=match)[:3]
522 status = repo.status(match=match)
523 523 diffopts = opts.copy()
524 524 diffopts['nodates'] = True
525 525 diffopts['git'] = True
526 526 diffopts = patch.diffopts(ui, opts=diffopts)
527 chunks = patch.diff(repo, changes=changes, opts=diffopts)
527 chunks = patch.diff(repo, changes=status, opts=diffopts)
528 528 fp = cStringIO.StringIO()
529 529 fp.write(''.join(chunks))
530 530 fp.seek(0)
@@ -544,13 +544,13 b' def dorecord(ui, repo, commitfunc, cmdsu'
544 544 except AttributeError:
545 545 pass
546 546
547 changed = changes[0] + changes[1] + changes[2]
547 changed = status.modified + status.added + status.removed
548 548 newfiles = [f for f in changed if f in contenders]
549 549 if not newfiles:
550 550 ui.status(_('no changes to record\n'))
551 551 return 0
552 552
553 modified = set(changes[0])
553 modified = set(status.modified)
554 554
555 555 # 2. backup changed files, so we can restore them in the end
556 556 if backupall:
General Comments 0
You need to be logged in to leave comments. Login now