hgext/githelp.py
changeset 43503 313e3a279828
parent 43117 8ff1ecfadcd1
child 43506 9f70512ae2cf
equal deleted inserted replaced
43502:c093cc6e6c99 43503:313e3a279828
    88     while True:
    88     while True:
    89         try:
    89         try:
    90             args = fancyopts.fancyopts(list(args), cmdoptions, opts, True)
    90             args = fancyopts.fancyopts(list(args), cmdoptions, opts, True)
    91             break
    91             break
    92         except getopt.GetoptError as ex:
    92         except getopt.GetoptError as ex:
    93             if r"requires argument" in ex.msg:
    93             if "requires argument" in ex.msg:
    94                 raise
    94                 raise
    95             if (r'--' + ex.opt) in ex.msg:
    95             if (r'--' + ex.opt) in ex.msg:
    96                 flag = b'--' + pycompat.bytestr(ex.opt)
    96                 flag = b'--' + pycompat.bytestr(ex.opt)
    97             elif (r'-' + ex.opt) in ex.msg:
    97             elif (r'-' + ex.opt) in ex.msg:
    98                 flag = b'-' + pycompat.bytestr(ex.opt)
    98                 flag = b'-' + pycompat.bytestr(ex.opt)