Smart way to compare drupal instance files with official release to search for modified files I was asked to update (just install new core and modules versions) a Drupal site that uses roughly 100 (yes: hundred) contributed modules. I suspect that some of these modules might have been modified, maybe including core.

I'm looking for a smart way that would allow me to utilize git (or some other tool) to automatically search for files that differ from the ones available in official release for specific module version (contributed or core).

I could use drush to dump installed modules names and versions or use some shell script to read that data from *.info files. Then I could use that to generate git commands. So in theory it is not that difficult. But that's just a theory :)

So any input on this would be helpful from people who did similar things. Any caveats? Maybe other approach or just some code examples?

Or maybe there is a Drupal module that can do this for me?
The Hacked! module is exactly what you're after:


  This module scans the currently installed Drupal, contributed modules
  and themes, re-downloads them and determines if they have been
  changed. Changes are marked clearly and if the diff module is
  installed then Hacked! will allow you to see the exact lines that have
  changed.