About mergemaster (Re: upgrading)

Jim C. Nasby jim at nasby.net
Tue Sep 23 07:35:05 PDT 2003


I think a far better solution would be to give mergemaster the ability
to compare files to the version in CVS as reported by the $FreeBSD$ tag.

Has the file changed (test that's currently done right now).
If no, don't worry.
Yes. Get the CVS tag from the file installed on the system.
Grab that version of the file from CVS (or maybe a local copy)
Compare the installed file to the one that's in CVS (we're comparing
    what should be the same versions of the file now)
Do they match? If they do, that means the file has never been edited,
    and it's safe to install the new one.
If they don't match, ask the user what to do.

Obviously, hitting the CVS server every time you come to a changed file
would be a bit slow, so it would probably be better to keep a local
copy. The technique is still the same though.

On Mon, Sep 22, 2003 at 06:41:16PM +0400, Dmitry Agafonov wrote:
> Hi!
> 
> I had a lot of different words to say into the air while upgrading :)
> I had only 5 FreeBSD boxes, so I can imagine others with 50, 100 or more :(
> 
> Most painful procedure for me is running mergemaster. Most of the job of 
> it can be
> done _automatically_, but it does not. Though indeed it already do much.
> I cannot see any reason to report me all the differences developers 
> bring into the
> distribution. I can use cvs to do that if I wish, am I right? I see the 
> problem in the
> inability of the mergemaster to detect changed (comparing to the 
> previous installation)
> file and to mark the file "clean".
> 
> I'm changing 2-3 system configs, so one can see changed file simply 
> comparing md5
> hash of the original file, say, in the "$MD5: " custom header (not 
> including that line itself
> while calculating hash, or it will be a big trick to produce such file).
> 
> How the idea?
> 
> --
> Dmitry
-- 
Jim C. Nasby, Database Consultant                  jim at nasby.net
Member: Triangle Fraternity, Sports Car Club of America
Give your computer some brain candy! www.distributed.net Team #1828

Windows: "Where do you want to go today?"
Linux: "Where do you want to go tomorrow?"
FreeBSD: "Are you guys coming, or what?"


More information about the freebsd-stable mailing list