ACK is a greplike tool optimized for programmers searching large heterogeneous trees of source code.

learn more… | top users | synonyms

1
vote
3answers
37 views

How to pick out files in a folder in which the header contains specific text?

Use case: Let's say there is a folder full of large RDF+XML files and they follow different namespaces. We want to find those files that follow a given namespace (for example ...
2
votes
1answer
47 views

How to search all text files in Ack? (with --text option being now removed)

Manual says that "The --text option has been removed.". It was setting the --type to text, i.e. ack was searching all text files regardless of their semantic category (i.e. in *.php files, *.txt ...
3
votes
2answers
85 views

ack/grep search and sort by modification date

Is there any way to have ack sort the results found by date of modification? (ideally showing the date next to the result?). It doesn't look like ack has a date option, but just in case. If this ...
3
votes
4answers
702 views

Search only in files that match a pattern with ack

Can ack search only through files that match a specific pattern (eg: search for foo in all files named "bar*.c"). The command ack foo "bar*.c" only works in the current directory. Note: I know ...
1
vote
3answers
160 views

Installing ack on cpanel

I need to install ack on an instance of whm/cpanel (I have root access as it is a VPS) but I have not found any information on how to do that. I tried to install it using the WHM RPM manager, but the ...
0
votes
2answers
1k views

How to do max-depth search in ack and grep?

Is there any way to tell ack to only search for text on the current folder? (or specify a max-depth level?) And with grep?
2
votes
2answers
340 views

Web front-end to find/grep/ack

In my lab, we are trying to build a web that allows the user to enter queries for find, ack, grep on a specific directory. The web would return an HTML with a table of a list of clickable files (click ...
6
votes
2answers
472 views

Search ALL files with ack

How can I search all files (including binary) in the current directory with ack v2? I want to do the same as doing ack 'foo' **, but just with a flag, so it works if I want to search all files in a ...
1
vote
2answers
234 views

Match a simple Regex

I need to match this: (tt\d{1,10}) in a file with the file ending txt. I have tried grep and ack-grep but without results. ack-grep -G \.txt$ -g "(tt\d{1,10})"