Show More
@@ -2772,14 +2772,15 b' def commitforceeditor(repo, ctx, subs, f' | |||
|
2772 | 2772 | |
|
2773 | 2773 | editortext = repo.ui.edit(committext, ctx.user(), ctx.extra(), |
|
2774 | 2774 | editform=editform, pending=pending) |
|
2775 | text = editortext | |
|
2775 | 2776 | |
|
2776 | 2777 | # strip away anything below this special string (used for editors that want |
|
2777 | 2778 | # to display the diff) |
|
2778 |
stripbelow = re.search(_linebelow, |
|
|
2779 | stripbelow = re.search(_linebelow, text, flags=re.MULTILINE) | |
|
2779 | 2780 | if stripbelow: |
|
2780 |
|
|
|
2781 | ||
|
2782 |
text = re.sub("(?m)^HG:.*(\n|$)", "", |
|
|
2781 | text = text[:stripbelow.start()] | |
|
2782 | ||
|
2783 | text = re.sub("(?m)^HG:.*(\n|$)", "", text) | |
|
2783 | 2784 | os.chdir(olddir) |
|
2784 | 2785 | |
|
2785 | 2786 | if finishdesc: |
@@ -712,6 +712,9 b' test that text below the --- >8 --- spec' | |||
|
712 | 712 | > EOF |
|
713 | 713 | $ echo foo2 > foo2 |
|
714 | 714 | $ hg add foo2 |
|
715 | $ HGEDITOR="sh $TESTTMP/notouching.sh" hg ci | |
|
716 | abort: commit message unchanged | |
|
717 | [255] | |
|
715 | 718 | $ HGEDITOR="sh $TESTTMP/lowercaseline.sh" hg ci |
|
716 | 719 | first line |
|
717 | 720 | HG: this is customized commit template |
General Comments 0
You need to be logged in to leave comments.
Login now