I tried ack -f --cpp --nohh
but it returns no results.
I'm using 2.14 on OSX.
I tried ack -f --cpp --nohh
but it returns no results.
I'm using 2.14 on OSX.
I apparently misread the question. I thought that the question implied that the user was seeing source files but not headers. If the desire is to show source files but not headers, the command stream ack -f --cpp --nohh should give the desired results and works for me. However, I have a number of samples of C and C++ code in my personal directory. What is your working directory when running the command? Do you have source and header files in your directory.
I am sorry if I misread your question.
http://beyondgrep.com is the web site for ack
... Previous answer
if you look at man ack, --nohh means to not include header files.
I just ran ack -f --hh --cpp on my Mac OS X with ack 2.12 and a great many header files appeared.
...
I am using Mac OS X El Capitan (Version 10.11.5) with ack 2.12