From 9e1b932e003587b99d5e06570b08023c88bf9a97 Mon Sep 17 00:00:00 2001 From: Michal Koutný Date: Feb 22 2023 13:06:00 +0000 Subject: scripts/renamepatches: Exclude search in irrelevant files Especially large files in kabi/ can be simply avoided on slow devices (or NFS). Suggested-by: Jiri Slaby --- diff --git a/scripts/renamepatches b/scripts/renamepatches index 8292b69..35b956a 100755 --- a/scripts/renamepatches +++ b/scripts/renamepatches @@ -29,7 +29,7 @@ fi branch=$1 trap 'rm -f "$temp"' EXIT temp=$(mktemp) -git grep -iE '^(Git-commit:|No-fix:|\(cherry picked from commit)' $branch | tr ':' ' ' | \ +git grep -iE '^(Git-commit:|No-fix:|\(cherry picked from commit)' $branch -- 'patches.*' | tr ':' ' ' | \ awk '!/patches.kernel.org/ {fn=$2; hash=$NF; map[hash]=map[hash] fn;} END { for (hash in map) printf("map[%s]=\"%s\"\n", hash, map[hash]); }' \ >$temp