1

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?

4

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.

7
  • 1
    Note: Safest to be used with Drush or you can expect HTTP 500, PHP timeout. Comparing like that is slow, even with batch api.
    – Mołot
    Oct 1 '13 at 8:51
  • @Mołot I've never had a problem using Hacked! through the UI (I've used it quite extensively as well). Never takes more than a couple of minutes to produce a full core/contrib report, never seen a 500 or timeout, even on sites with hundreds of contrib modules
    – Clive
    Oct 1 '13 at 8:57
  • 1
    @Clive maybe our servers was just that bad, then? You know how it is when management chooses hosting based on a price tag :p and I must admit they were good enough for Boosted sites with pretty heavy traffic and not a lot of edits.
    – Mołot
    Oct 1 '13 at 8:59
  • 1
    @Mołot I've never had a problem either, however I don't have many sites with that many modules. I think my top count is somewhere between 30 and 40. Good to bear in mind though! I guess if it's usable through Drush, then it's usable as part of a Phing build script (for example). Good to bear in mind :)
    – Chapabu
    Oct 1 '13 at 9:00
  • @Mołot Maybe, I run it all the time on my laptop and a local dev server (both Macs - urgh) without probs. Should be noted: never, ever install this on a production server :)
    – Clive
    Oct 1 '13 at 9:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.