Keeping Track of Core Hacks

6th Feb 2006 stk

I'm thinking that this would make for a good article for folks. I know, for me, I was actually "afraid" of upgrading, b/c I was gonna lose my core hacks and thought it was gonna be forever to get them back.

Having upgraded from Paris (our first b2evo install) -> Dawn and then -> v1.6 ... all recently, has taught me a better way to keep track.

Basically, what I do is this:

  1. In a mirrored directory tree, I make a local copy of a core file that I'm about to modify and rename it _coreFile-ORIG.php
  2. In my editor, I hack the file the way I want and save it as _coreFile-MOD.php
  3. When I upgrade, I then have a list of my "hacked" files that I can use a differencing program (like WinMerge, which I use and like).
  4. PLUS, I have the added benefit, if needed, of reverting back to the original file-state, if I really mess up my hackage or something.

Do either of you have a way of managing core hacks? (or suggestions/additions)? (This is really more a question for Danny and/or Ed, because I know that Blabba is a cowboy and probably doesn't have a method at all. :p )

The only thing that I've wanted in mine, is a relative level of importance (some core hacks are minor ... some critical). It would be nice to know which is which, so that WHEN I do upgrade, I can do the critical ones first ... though I usually do a parallel install with a copy of the DB and wait to go "live" till all core hacks are accounted for.

 
 
 
 

Comments

Anonymous
6th Feb 2006
I don't have anything better than that. I just keep a copy called backup.whatever.php right in with the modified one. When I upgrade I copy all the old files files to a new directory (called 170-alpha-blogs or something like that), so I can bring my hacks, plugins and skins back in to the new install one at a time. But I actually do very little hacking to core files.
 
Anonymous
7th Feb 2006
I find it quicker to write down all the lines of original code that's left after I've hacked :|

And yes we should invite EdB pronto, can we leave that to you?

¥
 
Anonymous
7th Feb 2006
Somehow i just KNEW that blabba could be counted on for a smart-assed answer. Thanks Danny ... at least it's confirmation there isn't some nifty, auto-hack-retaining OpenSource tool out there somewhere.

LOL ... Yabbio! ;)
 
 

Recent Comments

     
     

    Archives