comparison mercurial/commands.py @ 4879:da8640113b5a

Merge with -stable
author Matt Mackall <mpm@selenic.com>
date Sat, 14 Jul 2007 13:34:40 -0500
parents 192cd95c2ba8 242026115e6a
children 2d545b98a7bc
comparison
equal deleted inserted replaced
4876:001e8a745834 4879:da8640113b5a
1105 use the --all flag. 1105 use the --all flag.
1106 """ 1106 """
1107 reflags = 0 1107 reflags = 0
1108 if opts['ignore_case']: 1108 if opts['ignore_case']:
1109 reflags |= re.I 1109 reflags |= re.I
1110 regexp = re.compile(pattern, reflags) 1110 try:
1111 regexp = re.compile(pattern, reflags)
1112 except Exception, inst:
1113 ui.warn(_("grep: invalid match pattern: %s!\n") % inst)
1114 return None
1111 sep, eol = ':', '\n' 1115 sep, eol = ':', '\n'
1112 if opts['print0']: 1116 if opts['print0']:
1113 sep = eol = '\0' 1117 sep = eol = '\0'
1114 1118
1115 fcache = {} 1119 fcache = {}