buggrep - Bugs: bug #29876, --include not working as expected


You are not allowed to post comments on this tracker with your current authentication level.

bug #29876: --include not working as expected

Submitter:  None
Submitted:  Thu 13 May 2010 02:28:20 PM UTC
Category:  None Severity:  3 - Normal
Item Group:  None Status:  Fixed
Privacy:  Public Assigned to:  None
Open/Closed:  Closed

Sat 14 Aug 2010 08:23:45 PM UTC, comment #2: 

Thanks again for the report.
That bug is now fixed via this patch:


Jim Meyering <meyering>
Group administrator
Fri 23 Jul 2010 03:45:28 AM UTC, comment #1: 

2.6.3 --include doesn't work as 2.5.4 does.

For instance:

$ mkdir foo
$ cd foo
$ echo 1 > 1
$ echo 2 > 2
$ grep2.5.4 -P --include=[12] "\d" *
$ grep2.6.3 -P --include=[12] "\d" *

Joe Perches <joeperches>
Thu 13 May 2010 02:28:20 PM UTC, original submission:  

The --include option seems completely broken to me.  I am using v2.6.3 on Arch Linux.


# Normal recursive grep works ok...
[alan@perry] ~/test
$ grep -Rl test *

# test.cpp in the current directory isn't returned
[alan@perry] ~/test
$ grep -Rl --include=\*.cpp test *

# I only asked for .h files, why is a .cpp file being returned?
[alan@perry] ~/test
$ grep -Rl --include=\*.h test *

# Non-recursive, nothing gets returned.
[alan@perry] ~/test
$ grep -l --include=\*.cpp test *

# Non-recursive, wrong file type returned.
[alan@perry] ~/test
$ grep -l --include=\*.h test *

I've tried using various combinations of backslashes, single and double quotes on the --include parameter, but to no avail.



(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

No files currently attached


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -email is unavailable- added by meyering (Posted a comment)
  • -email is unavailable- added by bonzini (Updated the item)
  • -email is unavailable- added by joeperches (Posted a comment)

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.


    Follow 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2010-08-30 bonzini Open/ClosedOpen Closed
    2010-08-14 meyering StatusConfirmed Fixed
    2010-07-25 bonzini StatusNone Confirmed

    Back to the top

    Powered by Savane 3.12