Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SHELL

comparing file content bash

if diff -u "$file1" "$file2"; then
  echo "$file1 and $file2 have identical contents"
else
  : # the differences between the files have been listed
fi
Source by riptutorial.com #
 
PREVIOUS NEXT
Tagged: #comparing #file #content #bash
ADD COMMENT
Topic
Name
6+4 =