tests/unwrap-message-id.py
author Martin von Zweigbergk <martinvonz@google.com>
Wed, 09 Dec 2020 20:22:25 -0800
changeset 46115 be3d8178251e
parent 44405 a1908951ca42
child 48875 6000f5b25c9b
permissions -rw-r--r--
errors: raise InputError if an ambiguous revision id prefix is used It's long bothered me that we include the "00changelog.i" part in a message to the user. This fixes that along with the exit code. Differential Revision: https://phab.mercurial-scm.org/D9600

from __future__ import absolute_import, print_function

import sys

for line in sys.stdin:
    if line.lower() in ("message-id: \n", "in-reply-to: \n"):
        line = line[:-2]
    print(line, end="")