I am trying to locate a file or files with specific data in them. Problem is the file(s) could reside in any one of many directories.
My question is. Is there a way of recursively greping directories for the file(s) with the data I am looking for.
I have tried -
1.
$HOME> grep 47518 | ls... (8 Replies)
Hi! Suppose I have a directory (no symbolic links) called /WORK that contains 3 subdirectories:
/A
/B
/C
My problem is this: I want to look for a file that contains an order number. So far, I obtain what I want by doing this
/home/acb% cd /WORK/A
/home/acb/WORK/A% grep '093023553' *.*... (3 Replies)
I'm using this command to get a recursive grep
find . -name *.i -exec grep 'blah blah' {} \; -exec ls {} \;
now I would like to obtain just the list of the files and not also the line of the file.
How should I change the syntax?
thank you, (5 Replies)
When finding a string in files within a directory, one can use this:
grep -r "searchstring" dir/subdir/ > listofoccurrences.txt
For brevity sake one can enter the intended directory and use this:
grep -r "searchstring" . > listofoccurrences.txt
which as I found out leads to an endless loop,... (2 Replies)
Hi,
on AIX 6.1 , in man document for grep :
-r
Searches directories recursively. By default, links to directories are followed.
But when I use :
oracle@XXX:/appli/XXX_SCRIPTS#grep -r subject *.sh
It returns nothing.
However I have at least one row in a file :
... (3 Replies)
Tricky one:
I want to do several things all at once to blow away a directory (rm -rf <dir>)
1) I want to find all files recursively that have a specific file extension (.ver) for example.
2) Then in that file, I want to grep for an expression ( "sp2" ) for example.
3) Then I want to... (1 Reply)
I have seen some useful infomation about recursive grep in one of the thread. Can it is possible to combine resursive grep and replace togather? Means I need to replace old server names in all the files with new server names as we are upgrading our applications. There are lots of files in... (2 Replies)
Hi All,
This is the first time I have posted to this forum so please bear with me. Thanks also advance for any help or guidance.
For a project I need to do the following.
1. There are multiple files in multiple locations so I need to find them and the location. So I had planned to use... (9 Replies)
Can I please have some ideas on how to do a recursive grep with certain types of files? The file types I want to use are *.c and *.java.
I know this normally works with all files.
grep -riI 'scanner' /home/bob/ 2>/dev/null
Just not sure how to get it to work *.c and *.java files. (5 Replies)
Discussion started by: cokedude
5 Replies
LEARN ABOUT SUSE
gnome-search-tool
gnome-search-tool(1) General Commands Manual gnome-search-tool(1)NAME
gnome-search-tool - the GNOME Search Tool
SYNOPSIS
gnome-search-tool [options]
or select Search for Files... from a Main Menu or from the Places menu in a Menu Bar
DESCRIPTION
GNOME Search Tool is a utility for finding files on your system. To perform a basic search, you can type a filename or a partial filename,
with or without wildcards. To refine your search, you can apply additional search options.
GNOME Search Tool uses the find, grep, and locate UNIX commands. The case sensitivity of the search depends on your operating system. For
example, on Linux, the find, grep, and locate commands support the -i option, so all searches are case-insensitive.
For full documentation see the GNOME Search Tool online help.
OPTIONS --help Show help message
--named=STRING
Set the text of "Name contains" search option
--path=PATH
Set the text of "Look in folder" search option
--sortby=VALUE
Sort files by one of the following: name, folder, size, type, or date
--descending
Set sort order to descending, the default is ascending
--start
Automatically start a search
--contains=STRING
Select and set the "Contains the text" search option
--mtimeless=DAYS
Select and set the "Date modified less than" search option
--mtimemore=DAYS
Select and set the "Date modified more than" search option
--sizemore=KILOBYTES
Select and set the "Size at least" search option
--sizeless=KILOBYTES
Select and set the "Size at most" search option
--empty
Select the "File is empty" search option
--user=USER
Select and set the "Owned by user" search option
--group=GROUP
Select and set the "Owned by group" search option
--nouser
Select the "Owner is unrecognized" search option
--notnamed=STRING
Select and set the "Name does not contain" search option
--regex=PATTERN
Select and set the "Name matches regular expression" search option
--hidden
Select the "Show hidden and backup files" search option
--follow
Select the "Follow symbolic links" search option
--mounts
Select the "Exclude other filesystems" search option
AUTHOR
GNOME Search Tool was originally written by George Lebl (<jirka@5z.com>). Version 2 was written by Dennis M. Cranston (<den-
nis_cranston@yahoo.com>).
This manual page was originally written by Jochen Voss <voss@mathematik.uni-kl.de>. Version 2 was written by Dennis M. Cranston (<den-
nis_cranston@yahoo.com>).
SEE ALSO find(1), locate(1), grep(1)gnome-utils 2.27.1 March 16 2009 gnome-search-tool(1)