How to compare files with same names in two different directories using a shell script
bash, diff, shell
Solution
The diff command has a -r option to recursively compare directories:
diff -r /develop /main
Problem
Before moving on to use SVN, I used to manage my project by simply keeping a `/develop/` directory and editing and testing files there, then moving them to the `/main/` directory. When I decided to move to SVN, I needed to be sure that the directories were indeed in sync. So, what is a good way to write a shell script [ bash ] to recursively compare files with the same name in two different directories? Note: The directory names used above are for sample only. I do not recommend storing your code in the top level :).