(testsuite) Check for grep and ls invoked without "command", see README
This commit is contained in:
parent
a2e2f198d8
commit
d98e56fb07
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
gitgrep()
|
gitgrep()
|
||||||
{
|
{
|
||||||
local out=$(git grep -I -E -n "$1" | \
|
local out=$(git grep -I -P -n "$1" | \
|
||||||
grep -E '^(bash_completion|completions/|test/)' | \
|
grep -E '^(bash_completion|completions/|test/)' | \
|
||||||
grep -Fv 'test/runLint')
|
grep -Fv 'test/runLint')
|
||||||
if [ -n "$out" ] ; then
|
if [ -n "$out" ] ; then
|
||||||
@ -40,3 +40,6 @@ gitgrep $cmdstart'[ef]grep\b' \
|
|||||||
|
|
||||||
# TODO: $ in sed subexpression used as an anchor (POSIX BRE optional, not in
|
# TODO: $ in sed subexpression used as an anchor (POSIX BRE optional, not in
|
||||||
# Solaris/FreeBSD)
|
# Solaris/FreeBSD)
|
||||||
|
|
||||||
|
gitgrep '(?<!command)'$cmdstart'(grep|ls)(\s|$)' \
|
||||||
|
'invoke grep and ls with "command" prefix, e.g. "command grep"'
|
||||||
|
Loading…
x
Reference in New Issue
Block a user