bug-grep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug #32520] If you use --include -- grep does not recurse all subdirect


From: Keith Daniels
Subject: [bug #32520] If you use --include -- grep does not recurse all subdirectires
Date: Thu, 17 Feb 2011 17:24:51 +0000
User-agent: Opera/9.80 (X11; Linux x86_64; U; en) Presto/2.7.62 Version/11.01

URL:
  <http://savannah.gnu.org/bugs/?32520>

                 Summary: If you use --include -- grep does not recurse all
subdirectires
                 Project: grep
            Submitted by: keithwdaniels
            Submitted on: Thu 17 Feb 2011 05:24:50 PM GMT
                Category: None
                Severity: 3 - Normal
              Item Group: None
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open
         Discussion Lock: Any

    _______________________________________________________

Details:


The testing below was based on the example 

    grep -rH --include='*.c' 'hello' /home/gigi" 

from the grep 2.7 Info file.


I found two problems which I think are related:


Problem #1:

If you use --include grep does not recurse all subdirectories.

Converting the Info example above to my situation gives incomplete recursion
when this is run:

     grep -rH --include='*.rc' 'extraToolBar' /home/$USER/.kde3/share    


While this gives complete recursion when it is run:

    grep -rH 'extraToolBar' /home/$USER/.kde3/share



Problem #2:

When specifying the path and globbing the file names the results appear to be
inconsistent. I would have expected

   /home/$USER/.kde3/share/*.rc 

to work and 

   /home/$USER/.kde3/share/ *.rc 

NOT to work.

Instead....

Running this gives complete recursion:

    grep -rH  'extraToolBar' /home/$USER/.kde3/share/*


Running this does not work at all:

    grep -rH 'extraToolBar' /home/$USER/.kde3/share/*.rc


Running this gives complete recursion -- BUT -- gives the error message "grep:
*.rc: No such file or directory" at the end:

    grep -rH 'extraToolBar' /home/$USER/.kde3/share/ *.rc






    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?32520>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]