There's a special place in hell for people who hardcode absolute paths and database credentials into multiple random places in web applications. Sadly, before they go to hell they're wreaking havoc on Earth. And we have to deal with their code.
I have to perform a few small changes to one of such web applications. I create a new branch features
, and perform a global find & replace to update the paths and credentials to my local environment. I commit that. I also tag this as local
.
I merrily leap into perilous hacking penitence, and after a perplexing hundred patches, I want to merge my features
changes into the master
branch, but I do not want the one local
commit to be merged.
Onwards, I'll be merging back and forth between master
and features
, and I'd like local
to stay put in features
, and never ever show up in master
.
Ideally, I'd like all this to happen magically, with as little funny parameters and whatnot as possible.
Is there a simple obvious way to do it that I'm missing?
I can think of a couple, but they all require me to remember that I don't want that commit. And that's definitely not my forte. Especially with such poorly hacked programs.
Failing that, I'm interested in more convoluted, manual-ish ways to handle the situation.