mercurial/patch.py
changeset 15159 85322c19c831
parent 15089 bfe903b1ff4e
parent 15158 7ce7177e029a
child 15201 2c4fdee4d1a8
equal deleted inserted replaced
15156:143c78b4fc8c 15159:85322c19c831
   186         if subject:
   186         if subject:
   187             if subject.startswith('[PATCH'):
   187             if subject.startswith('[PATCH'):
   188                 pend = subject.find(']')
   188                 pend = subject.find(']')
   189                 if pend >= 0:
   189                 if pend >= 0:
   190                     subject = subject[pend + 1:].lstrip()
   190                     subject = subject[pend + 1:].lstrip()
   191             subject = subject.replace('\n\t', ' ')
   191             subject = re.sub(r'\n[ \t]+', ' ', subject)
   192             ui.debug('Subject: %s\n' % subject)
   192             ui.debug('Subject: %s\n' % subject)
   193         if user:
   193         if user:
   194             ui.debug('From: %s\n' % user)
   194             ui.debug('From: %s\n' % user)
   195         diffs_seen = 0
   195         diffs_seen = 0
   196         ok_types = ('text/plain', 'text/x-diff', 'text/x-patch')
   196         ok_types = ('text/plain', 'text/x-diff', 'text/x-patch')