How to compare two strings in a file

hello guyzz

please help me out..

I have two file a.sh and b.sh it contains two string SD109 ,SD108 .

I want to compaere these two string .

If a.sh>b.sh

do rebasing

record time.

else it shows no rebasing required.

Thanks.

if diff a.sh b.sh > /dev/null
then
  echo "same, no rebasing required."
else
  echo "not same"
  do rebasing 
  record time
fi