diff options
| author | Alejandro Colomar <alx.manpages@gmail.com> | 2022-05-09 00:10:49 +0200 |
|---|---|---|
| committer | Alejandro Colomar <alx@kernel.org> | 2025-10-29 21:28:47 +0100 |
| commit | b8c9b7209e02a135d5e1e102a8ace60a70e45dba (patch) | |
| tree | 9ecc8338f320404f9f4a5b7734ac2d56835b233c /bin/grepc | |
| parent | 61a8cb713a76a5cc32315b23e2f41d9e24d98dda (diff) | |
| download | man-pages-b8c9b7209e02a135d5e1e102a8ace60a70e45dba.tar.gz | |
grepc: Allow tabs
Signed-off-by: Alejandro Colomar <alx.manpages@gmail.com>
Diffstat (limited to 'bin/grepc')
| -rwxr-xr-x | bin/grepc | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -147,9 +147,9 @@ function grepc_type_typedef_underlying_struct_union_enum() { find . -type f \ | grep '\.[ch]$' \ - | xargs grep -hP "^typedef .* *\b$1;" \ - | sed -E -e 's/^typedef //' -e "s/ *\b$1;.*//" \ - | sed -e 's/^struct //' -e 's/^union //' -e 's/^enum //' \ + | xargs grep -hP "^typedef\s+.*\b$1;" \ + | sed -E -e 's/^typedef\s+//' -e "s/\s*\**\b$1;.*//" \ + | sed -E -e 's/^struct\s+//' -e 's/^union\s+//' -e 's/^enum\s+//' \ | while read t; do grepc_type_struct_union_enum "$t"; done; |
