[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: cvs ignore feature

From: Pierre Asselin
Subject: Re: cvs ignore feature
Date: Sat, 25 Dec 2004 23:53:15 +0000 (UTC)
User-agent: tin/1.6.1-20030810 ("Mingulay") (UNIX) (NetBSD/2.0 (i386))

Jeff Decker <address@hidden> wrote:

> [ ... ] My question is I am getting the project from 
> a repository that already has files in it but once I get the file I want 
> cvs to ignore any future changes I make to the file. 

As others have told you, cvsignore won't do that.

> The reason I need to do this is because we have build scripts that I 
> will modify to work on my system but if I commit the changes then it 
> won't work on the official build machine.

What you should do is try very hard to modify the scripts
so they work on all systems.  Writing portable code is such a joy.
If you break a script, I'm sure your colleagues will let you know.

Having said this, you could deliberately plant a sticky release
tag on the files that get changed, to make sure you never commit
the changes.  I think this will work,
    cvs update -rBASE file1 file2 ...

but you may have to do it manually by revision number,
    cvs status file1
    cvs update -r1.whatever file1

If you now try to commit one of these changed files, you will
be tossed out.  To commit your tree wholesale, minus the bad files,
you'll have to get the unmodified versions,
    rm file1 file2 ...
    cvs update file1 file2 ...
    U file1
    U file2
    cvs commit

If the files have changed in the repository, the only way for you
to get the new versions is to remove the sticky tag and plant
a new one.
    rm file1 file2 ...
    cvs update -A file1 file2 ...
    cvs update -rBASE file1 file2 ... # I hope

Omit the "rm" command if you want to merge your changes into
a local copy of the latest, instead of starting from scratch.

pa at panix dot com

reply via email to

[Prev in Thread] Current Thread [Next in Thread]