Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

gzipped/compressed files as input to

Posted on 1997-08-28
9
310 Views
Last Modified: 2010-04-21
i want to comm or diff two files that are gzipped and i am pressed for space.  is there any way to 'gunzip -c' the files and pipe them directly to comm or diff?
0
Comment
Question by:luke_airig
  • 5
  • 3
9 Comments
 
LVL 84

Expert Comment

by:ozo
ID: 2006837
You can pipe one of them to comm or diff as the filename -

piping two may be more difficult...
perhaps you could manage to pipe to /dev/pty...
 
 
0
 
LVL 51

Accepted Solution

by:
ahoffmann earned 10 total points
ID: 2006838
If you have gzip/gunzip, you also should have zdiff:
      zdiff a.gz b.gz

0
 
LVL 84

Expert Comment

by:ozo
ID: 2006839
which pipes a.gz to -, but uncompresses b.gz to a temp file

0
Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 51

Expert Comment

by:ahoffmann
ID: 2006840
ozo, where did you find this information? I'm interested too :-)
0
 
LVL 84

Expert Comment

by:ozo
ID: 2006841
cat `which zdiff`

Also, running it and seeing:
- /tmp/b differ: char n, line m
gives a clue
(if that's what ahoffmann is asking)
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 2006842
It's so easy: just reading what's written :-))
Thanx ozo.

luke_airig, sorry but I think my answer doesn't solve your problem :-(
0
 
LVL 84

Expert Comment

by:ozo
ID: 2006843
It solves half the problem.
Which may be enough...
(But surely there must be a utility somewhere
to connect two /dev/pipe devices together?)



0
 
LVL 84

Expert Comment

by:ozo
ID: 2006844
It solves half the problem.
Which may be enough...
(But surely there must be a utility somewhere
to connect two /dev/pipe devices together?)



0
 

Author Comment

by:luke_airig
ID: 2006845
ahoffman and ozo,

zdiff is exactly what i needed.  thanks for your help.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In tuning file systems on the Solaris Operating System, changing some parameters of a file system usually destroys the data on it. For instance, changing the cache segment block size in the volume of a T3 requires that you delete the existing volu…
Why Shell Scripting? Shell scripting is a powerful method of accessing UNIX systems and it is very flexible. Shell scripts are required when we want to execute a sequence of commands in Unix flavored operating systems. “Shell” is the command line i…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…

829 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question