1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
#!/bin/bash # # Comparing file1 and file2 # # Usage # compare-text.sh file1 file2 [--verbose] # # To-do # Processing arguments # # Return code: make use of `comm' # file1=$1 file2=$2 message_if_matched=$3 message_if_not_matched=$4 comm $file1 $file2 > /dev/null 2>&1 |