Show More
@@ -1455,9 +1455,10 b' class queue(object):' | |||
|
1455 | 1455 | |
|
1456 | 1456 | try: |
|
1457 | 1457 | # might be nice to attempt to roll back strip after this |
|
1458 | patchf.rename() | |
|
1459 | 1458 | n = repo.commit(message, user, ph.date, match=match, |
|
1460 | 1459 | force=True) |
|
1460 | # only write patch after a successful commit | |
|
1461 | patchf.rename() | |
|
1461 | 1462 | self.applied.append(statusentry(n, patchfn)) |
|
1462 | 1463 | except: |
|
1463 | 1464 | ctx = repo[cparents[0]] |
@@ -487,3 +487,38 b' Issue1441 with git patches:' | |||
|
487 | 487 | |
|
488 | 488 | $ cd .. |
|
489 | 489 | |
|
490 | Refresh with bad usernames. Mercurial used to abort on bad usernames, | |
|
491 | but only after writing the bad name into the patch. | |
|
492 | ||
|
493 | $ hg init bad-usernames | |
|
494 | $ cd bad-usernames | |
|
495 | $ touch a | |
|
496 | $ hg add a | |
|
497 | $ hg qnew a | |
|
498 | $ hg qrefresh -u 'foo | |
|
499 | > bar' | |
|
500 | transaction abort! | |
|
501 | rollback completed | |
|
502 | refresh interrupted while patch was popped! (revert --all, qpush to recover) | |
|
503 | abort: username 'foo\nbar' contains a newline! | |
|
504 | [255] | |
|
505 | $ cat .hg/patches/a | |
|
506 | # HG changeset patch | |
|
507 | # Parent 0000000000000000000000000000000000000000 | |
|
508 | diff --git a/a b/a | |
|
509 | new file mode 100644 | |
|
510 | $ hg qpush | |
|
511 | applying a | |
|
512 | now at: a | |
|
513 | $ hg qrefresh -u ' ' | |
|
514 | transaction abort! | |
|
515 | rollback completed | |
|
516 | refresh interrupted while patch was popped! (revert --all, qpush to recover) | |
|
517 | abort: empty username! | |
|
518 | [255] | |
|
519 | $ cat .hg/patches/a | |
|
520 | # HG changeset patch | |
|
521 | # Parent 0000000000000000000000000000000000000000 | |
|
522 | diff --git a/a b/a | |
|
523 | new file mode 100644 | |
|
524 | $ cd .. |
General Comments 0
You need to be logged in to leave comments.
Login now