##// END OF EJS Templates
grep: reject --diff --all-files...
Yuya Nishihara -
r38671:0d0f8bd6 default
parent child Browse files
Show More
@@ -2533,6 +2533,9 b' def grep(ui, repo, pattern, *pats, **opt'
2533 """
2533 """
2534 opts = pycompat.byteskwargs(opts)
2534 opts = pycompat.byteskwargs(opts)
2535 diff = opts.get('all') or opts.get('diff')
2535 diff = opts.get('all') or opts.get('diff')
2536 if diff and opts.get('all_files'):
2537 raise error.Abort(_('--diff and --all-files are mutually exclusive'))
2538
2536 reflags = re.M
2539 reflags = re.M
2537 if opts.get('ignore_case'):
2540 if opts.get('ignore_case'):
2538 reflags |= re.I
2541 reflags |= re.I
@@ -412,6 +412,12 b' Test for showing working of allfiles fla'
412 $ hg grep -r "." "unmod" --all-files
412 $ hg grep -r "." "unmod" --all-files
413 um:1:unmod
413 um:1:unmod
414
414
415 --diff --all-files makes no sense since --diff is the option to grep history
416
417 $ hg grep --diff --all-files um
418 abort: --diff and --all-files are mutually exclusive
419 [255]
420
415 $ cd ..
421 $ cd ..
416
422
417 Fix_Wdir(): test that passing wdir() t -r flag does greps on the
423 Fix_Wdir(): test that passing wdir() t -r flag does greps on the
General Comments 0
You need to be logged in to leave comments. Login now