devtools: fix escaped space in grep pattern

Message ID 20230110213317.1146005-1-thomas@monjalon.net (mailing list archive)
State Accepted, archived
Delegated to: Thomas Monjalon
Headers
Series devtools: fix escaped space in grep pattern |

Checks

Context Check Description
ci/checkpatch warning coding style issues
ci/loongarch-compilation success Compilation OK
ci/loongarch-unit-testing success Unit Testing PASS
ci/iol-broadcom-Performance success Performance Testing PASS
ci/Intel-compilation success Compilation OK
ci/iol-intel-Functional success Functional Testing PASS
ci/intel-Testing success Testing PASS
ci/iol-intel-Performance success Performance Testing PASS
ci/github-robot: build fail github build: failed
ci/iol-mellanox-Performance success Performance Testing PASS
ci/iol-abi-testing success Testing PASS
ci/iol-aarch64-compile-testing success Testing PASS
ci/iol-x86_64-compile-testing success Testing PASS
ci/iol-aarch64-unit-testing success Testing PASS
ci/iol-testing success Testing PASS
ci/iol-x86_64-unit-testing success Testing PASS

Commit Message

Thomas Monjalon Jan. 10, 2023, 9:33 p.m. UTC
  Since grep 3.8, a warning is printed if a space is escaped in a pattern:
	grep: warning: stray \ before white space

There was an occurence of such extra backslash in check-git-log.sh.

Fixes: d448efa259e9 ("devtools: export dictionary for commit title check")
Cc: stable@dpdk.org

Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
---
 devtools/check-git-log.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
  

Comments

Tyler Retzlaff Jan. 10, 2023, 9:52 p.m. UTC | #1
On Tue, Jan 10, 2023 at 10:33:17PM +0100, Thomas Monjalon wrote:
> Since grep 3.8, a warning is printed if a space is escaped in a pattern:
> 	grep: warning: stray \ before white space
> 
> There was an occurence of such extra backslash in check-git-log.sh.
> 
> Fixes: d448efa259e9 ("devtools: export dictionary for commit title check")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
> ---

thanks, it was annoying.

Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
  
Thomas Monjalon Jan. 11, 2023, 8:57 a.m. UTC | #2
10/01/2023 22:52, Tyler Retzlaff:
> On Tue, Jan 10, 2023 at 10:33:17PM +0100, Thomas Monjalon wrote:
> > Since grep 3.8, a warning is printed if a space is escaped in a pattern:
> > 	grep: warning: stray \ before white space
> > 
> > There was an occurence of such extra backslash in check-git-log.sh.
> > 
> > Fixes: d448efa259e9 ("devtools: export dictionary for commit title check")
> > Cc: stable@dpdk.org
> > 
> > Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
> > ---
> 
> thanks, it was annoying.
> 
> Acked-by: Tyler Retzlaff <roretzla@linux.microsoft.com>

Applied
  

Patch

diff --git a/devtools/check-git-log.sh b/devtools/check-git-log.sh
index 01d8aa0717..e26205814b 100755
--- a/devtools/check-git-log.sh
+++ b/devtools/check-git-log.sh
@@ -120,7 +120,7 @@  words="$selfdir/words-case.txt"
 for word in $(cat $words); do
 	bad=$(echo "$headlines" | grep -iw $word | grep -vw $word)
 	if [ "$word" = "Tx" ]; then
-		bad=$(echo $bad | grep -v 'OCTEON\ TX')
+		bad=$(echo $bad | grep -v 'OCTEON TX')
 	fi
 	for bad_line in $bad; do
 		bad_word=$(echo $bad_line | cut -d":" -f2 | grep -iwo $word)