Advertisement
adilima

compare md5sums

Dec 3rd, 2014
393
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.35 KB | None | 0 0
  1. code1=$(cat $1 | cut -d'=' -f2)
  2.  
  3. code2=$(cat $2 | cut -d'=' -f2)
  4.  
  5.  
  6.  
  7. for tok1 in $code1do
  8.  
  9.   bVal=0
  10.  
  11.   for tok2 in $code2do
  12.  
  13.     if [ $tok1 == $tok2 ]then
  14.  
  15.       bVal=1
  16.  
  17.       echo "$tok1 == $tok2"
  18.  
  19.       done
  20.  
  21.     fi
  22.  
  23.   done
  24.  
  25.   if [ bVal == 0 ]then
  26.  
  27.     echo "$tok1 NOT FOUND"
  28.  
  29.   fi
  30.  
  31. done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement