##// END OF EJS Templates
grep: levarage cmdutil.check_incompatible_arguments()...
Martin von Zweigbergk -
r46333:4f7309fd default
parent child Browse files
Show More
@@ -3365,11 +3365,10 b' def grep(ui, repo, pattern, *pats, **opt'
3365 Returns 0 if a match is found, 1 otherwise.
3365 Returns 0 if a match is found, 1 otherwise.
3366
3366
3367 """
3367 """
3368 cmdutil.check_incompatible_arguments(opts, 'all_files', ['all', 'diff'])
3368 opts = pycompat.byteskwargs(opts)
3369 opts = pycompat.byteskwargs(opts)
3369 diff = opts.get(b'all') or opts.get(b'diff')
3370 diff = opts.get(b'all') or opts.get(b'diff')
3370 follow = opts.get(b'follow')
3371 follow = opts.get(b'follow')
3371 if diff and opts.get(b'all_files'):
3372 raise error.Abort(_(b'--diff and --all-files are mutually exclusive'))
3373 if opts.get(b'all_files') is None and not diff:
3372 if opts.get(b'all_files') is None and not diff:
3374 opts[b'all_files'] = True
3373 opts[b'all_files'] = True
3375 plaingrep = (
3374 plaingrep = (
General Comments 0
You need to be logged in to leave comments. Login now