Results 1 to 4 of 4
Hi,
I need a script to compare two files.
I don’t care if it is in gerp, sed, awk or perl.
I like to compare /etc/passwd to /etc/mail/aliases.
If a ...
- 09-01-2005 #1Just Joined!
- Join Date
- Aug 2005
- Posts
- 3
Scripts
Hi,
I need a script to compare two files.
I don’t care if it is in gerp, sed, awk or perl.
I like to compare /etc/passwd to /etc/mail/aliases.
If a user in /etc/passwd is not in /etc/mail/aliases, I would like the output to be redirect to a third file.
- 09-01-2005 #2Just Joined!
- Join Date
- Jul 2005
- Posts
- 19
try use diff
Hi,
Try using a bash script with diff as in:
#!/bin/bash
diff /etc/passwd /etc/mail/alias > ~/filename.txt
Regards
- 09-02-2005 #3Just Joined!
- Join Date
- Aug 2005
- Posts
- 3
Thanks i will give it a try.
- 09-02-2005 #4Just Joined!
- Join Date
- Aug 2005
- Posts
- 3
I'm sorry that did not work, the two file are to different. This work best with two versions of the same file or an edit of one file.


Reply With Quote
