All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] find_repeated_words.sh: Do not process files that are redirects.
@ 2015-03-15  0:15 Stéphane Aulery
       [not found] ` <1426378524-31758-1-git-send-email-saulery-GANU6spQydw@public.gmane.org>
  0 siblings, 1 reply; 2+ messages in thread
From: Stéphane Aulery @ 2015-03-15  0:15 UTC (permalink / raw)
  To: mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w
  Cc: Stéphane Aulery, linux-man-u79uwXL29TY76Z2rM5mHXA

Signed-off-by: Stéphane Aulery <saulery-GANU6spQydw@public.gmane.org>
---
 scripts/find_repeated_words.sh | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/scripts/find_repeated_words.sh b/scripts/find_repeated_words.sh
index 50133be..747872e 100644
--- a/scripts/find_repeated_words.sh
+++ b/scripts/find_repeated_words.sh
@@ -25,6 +25,9 @@
 #
 
 for file in "$@" ; do 
+   # Do not process files that are redirects.
+   grep -qE "^\.so man.*" "$file"
+   if test $? -ne 0; then
     words=$(MANWIDTH=2000 man -l "$file" 2> /dev/null | col -b | \
 	tr ' \008' '\012' | sed -e '/^$/d' | \
 	sed 's/ *$//' | 
@@ -33,4 +36,5 @@ for file in "$@" ; do
     if test -n "$words"; then
         echo "$file: $words"
     fi
+   fi
 done
-- 
2.1.4

--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] find_repeated_words.sh: Do not process files that are redirects.
       [not found] ` <1426378524-31758-1-git-send-email-saulery-GANU6spQydw@public.gmane.org>
@ 2015-03-22 15:39   ` Michael Kerrisk (man-pages)
  0 siblings, 0 replies; 2+ messages in thread
From: Michael Kerrisk (man-pages) @ 2015-03-22 15:39 UTC (permalink / raw)
  To: Stéphane Aulery
  Cc: mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w, linux-man-u79uwXL29TY76Z2rM5mHXA

On 03/15/2015 01:15 AM, Stéphane Aulery wrote:
> Signed-off-by: Stéphane Aulery <saulery-GANU6spQydw@public.gmane.org>

Thanks, Stéphane. Patch applied.

Cheers,

Michael


> ---
>  scripts/find_repeated_words.sh | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/scripts/find_repeated_words.sh b/scripts/find_repeated_words.sh
> index 50133be..747872e 100644
> --- a/scripts/find_repeated_words.sh
> +++ b/scripts/find_repeated_words.sh
> @@ -25,6 +25,9 @@
>  #
>  
>  for file in "$@" ; do 
> +   # Do not process files that are redirects.
> +   grep -qE "^\.so man.*" "$file"
> +   if test $? -ne 0; then
>      words=$(MANWIDTH=2000 man -l "$file" 2> /dev/null | col -b | \
>  	tr ' \008' '\012' | sed -e '/^$/d' | \
>  	sed 's/ *$//' | 
> @@ -33,4 +36,5 @@ for file in "$@" ; do
>      if test -n "$words"; then
>          echo "$file: $words"
>      fi
> +   fi
>  done
> 


-- 
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Linux/UNIX System Programming Training: http://man7.org/training/
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-03-22 15:39 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-03-15  0:15 [PATCH] find_repeated_words.sh: Do not process files that are redirects Stéphane Aulery
     [not found] ` <1426378524-31758-1-git-send-email-saulery-GANU6spQydw@public.gmane.org>
2015-03-22 15:39   ` Michael Kerrisk (man-pages)

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.