[Bash-completion-commits] [bash-completion] 01/03: (testsuite) Check for grep and ls invoked without "command", see README
Ville Skyttä
scop-guest at moszumanska.debian.org
Mon Jan 6 15:48:35 UTC 2014
This is an automated email from the git hooks/post-receive script.
scop-guest pushed a commit to branch master
in repository bash-completion.
commit d98e56fb0725f96a5cb39362c2d9a60a39e69154
Author: Ville Skyttä <ville.skytta at iki.fi>
Date: Mon Jan 6 17:27:05 2014 +0200
(testsuite) Check for grep and ls invoked without "command", see README
---
test/runLint | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/test/runLint b/test/runLint
index 88c717a..347adc6 100755
--- a/test/runLint
+++ b/test/runLint
@@ -2,7 +2,7 @@
gitgrep()
{
- local out=$(git grep -I -E -n "$1" | \
+ local out=$(git grep -I -P -n "$1" | \
grep -E '^(bash_completion|completions/|test/)' | \
grep -Fv 'test/runLint')
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
# Solaris/FreeBSD)
+
+gitgrep '(?<!command)'$cmdstart'(grep|ls)(\s|$)' \
+ 'invoke grep and ls with "command" prefix, e.g. "command grep"'
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/bash-completion/bash-completion.git
More information about the Bash-completion-commits
mailing list