GZGREP(1) General Commands Manual GZGREP(1)NAME
gzgrep, gzegrep, gzfgrep - search possibly compressed files for a regular expression
SYNOPSIS
gzgrep [ grep_options ] [ -e ] pattern filename...
DESCRIPTION
gzgrep is used to invoke the grep on compress'ed or gzip'ed files. All options specified are passed directly to grep. If no file is speci-
fied, then the standard input is decompressed if necessary and fed to grep. Otherwise the given files are uncompressed if necessary and
fed to grep.
If gzgrep is invoked as gzegrep or gzfgrep then egrep or fgrep is used instead of grep. If the GREP environment variable is set, gzgrep
uses it as the grep program to be invoked. For example:
for sh: GREP=fgrep gzgrep string files
for csh: (setenv GREP fgrep; gzgrep string files)
AUTHOR
Charles Levert (charles@comm.polymtl.ca)
SEE ALSO grep(1), egrep(1), fgrep(1), gzdiff(1), gzmore(1), gznew(1), gzforce(1), gzip(1), gzexe(1)ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+--------------------+-----------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+--------------------+-----------------+
|Availability | SUNWgzip |
+--------------------+-----------------+
|Interface Stability | External |
+--------------------+-----------------+
NOTES
Source for gzip is available in the SUNWgzipS package.
GZGREP(1)
Check Out this Related Man Page
GZGREP(1) General Commands Manual GZGREP(1)NAME
gzgrep, gzegrep, gzfgrep - search possibly compressed files for a regular expression
SYNOPSIS
gzgrep [ grep_options ] [ -e ] pattern filename...
DESCRIPTION
gzgrep is used to invoke the grep on compress'ed or gzip'ed files. All options specified are passed directly to grep. If no file is speci-
fied, then the standard input is decompressed if necessary and fed to grep. Otherwise the given files are uncompressed if necessary and
fed to grep.
If gzgrep is invoked as gzegrep or gzfgrep then egrep or fgrep is used instead of grep. If the GREP environment variable is set, gzgrep
uses it as the grep program to be invoked. For example:
for sh: GREP=fgrep gzgrep string files
for csh: (setenv GREP fgrep; gzgrep string files)
AUTHOR
Charles Levert (charles@comm.polymtl.ca)
SEE ALSO grep(1), egrep(1), fgrep(1), gzdiff(1), gzmore(1), gznew(1), gzforce(1), gzip(1), gzexe(1)ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+--------------------+-----------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+--------------------+-----------------+
|Availability | SUNWgzip |
+--------------------+-----------------+
|Interface Stability | External |
+--------------------+-----------------+
NOTES
Source for gzip is available in the SUNWgzipS package.
GZGREP(1)
How can I do an and condition with fgrep.
I want to do:
ps -ef | fgrep -f searchvalues > tempmail.file
mailx -s "Email Subject" email@domain.com < tempmail.file
The search values file contains:
opt/bea.*java.*80
mysqld
What I want is to find things that contain:
mysqld OR... (7 Replies)
Hi all,
I am trying to perform a simple task with grep, this is what I execute:
grep -i -n 'error|fail|warning' cl_less.out
when I execute it it does not give any errors, as in the command worked and back to the command prompt, but if I run each grep independently the I do get a real fail:
... (8 Replies)
I have a file that looks like this:
Name=TOM
abcded
asdfas
fkoiaerj
inadhah
Name=Chris
23nafds
vasdkfna
afadns
afdadsfa
aaaaaa
bbbbbb
cccccc
I would to search for the string 'bbbbbb', then I would like to search above that string for the 1st occurrence of "Name" and not the other... (7 Replies)
Hello All,
I am trying to write a script to search in my current directory to look for all files that end with HTML and look for any HTML tags that are in upper case. for example if I were to grep test.html and test.html has a tag <P> instead of <p> then it would print the file name. This is... (11 Replies)
Hi
Is there any way GREP command can return word and not complete line.
My file has following data:
Hello Everyone I am NitinrajSrivastava
Hi Friends Welcome VrajSrivastava
I am using grep 'raj' which is returning me complete line.However I want only the word having keyword 'raj'.
Required... (11 Replies)
I have got this piece of csh code that looks into various log files and outputs some parameters
For example, I might have 4 files and want to grep for the lines containing "Best Value"
npt02-z30-sr65-rgdt0p50-dc0p004-16x12drw.log
npt02-z30-sr65-rgdt0p50-dc0p004-16x12drw-run2.log... (6 Replies)
Hi
We have several folders and subfolders in a heirarchy, representing clients and files we send to them. Files that are not processed are placed in reject folder. I am able to run a LS that will scan all these folders, and ones that show entries (rejected files) are seen here. I am looking for... (8 Replies)
1. The problem statement, all variables and given/known data:
Hey there, I'm brand new to using Unix as I just started a course on it in my University, and I currently working through a worksheet which focuses on the many commands and methods of GREP (I'm working through the terminal command... (11 Replies)
Can someone please help me to learn how to deal with loops, arrays and grep?
I have two arrays (lets say I and j) each in a separate file
And have file with lines of data I need to extract, such as
Ruby Smith: some text here
Ruby Smith: some other text here
Ruby Brown: some text here
Ruby... (10 Replies)
Hi,
I have a list of zipped files. I want to grep for a string in all files and get a list of file names that contain the string. But without unzipping them before that, more like using something like gzcat.
My OS is:
SunOS test 5.10 Generic_142900-13 sun4u sparc SUNW,SPARC-Enterprise (8 Replies)
Hallo gentlemen,
i've a problem removing lines from txt file. To make it simple, here is an example:
TEXT1.TXT --- contents:
9.9.9.9 geek.net
1.1.1.1 geek.com
2.2.2.2 leet.net
TEXT2.TXT --- contents:
geek.com
coolbar.org
I simply do:
cat text1.txt | grep -f text2.txt >... (7 Replies)
Hi,
I am Shell script beginner.
I wrote a shell programming that will take each line of a file1 and search for it in another file2 and give me the output of the lines that do not exist in the file2.
I wrote it using do while nested loop but the problem here is its running for ever . Is there... (12 Replies)