Re: Retrieving deleted file from the Attic

2002-11-14 Thread Larry Jones
Jason Yeung writes:
 
 I was wondering if it's possible to recover a file that is in the Attic
 directory? When you remove a file (and committed), the file gets copied to
 the Attic directory. For all purposes, it's removed from the repository.

Hardly -- you can still use most CVS commands on the file, you just have
to give the file name explicitly since there's no local file:

bash-2.02$ ls foo
ls: foo: No such file or directory

bash-2.02$ cvs status foo
===
File: no file foo   Status: Up-to-date

   Working revision:No entry for foo
   Repository revision: 1.3 /tmp/cvstest/test/Attic/foo,v

bash-2.02$ cvs log foo

RCS file: /tmp/cvstest/test/Attic/foo,v
Working file: foo
head: 1.3
branch:
locks: strict
access list:
symbolic names:
keyword substitution: kv
total revisions: 3; selected revisions: 3
description:

revision 1.3
date: 2002/11/14 16:06:49;  author: scjones;  state: dead;  lines: +0 -0
.

revision 1.2
date: 2002/11/14 16:06:38;  author: scjones;  state: Exp;  lines: +1 -1
.

revision 1.1
date: 2002/11/14 16:06:31;  author: scjones;  state: Exp;
.
=

As explained in the CVS manual, you can resurrect a removed file by
undoing the change that removed it:

bash-2.02$ cvs up -j1.3 -j1.2 foo
U foo

bash-2.02$ cvs status foo
===
File: foo   Status: Locally Added

   Working revision:New file!
   Repository revision: 1.3 /tmp/cvstest/test/Attic/foo,v
   Sticky Tag:  (none)
   Sticky Date: (none)
   Sticky Options:  (none)

bash-2.02$ cvs ci -m.
cvs commit: Examining .
Checking in foo;
/tmp/cvstest/test/foo,v  --  foo
new revision: 1.4; previous revision: 1.3
done

bash-2.02$ cvs status foo
===
File: foo   Status: Up-to-date

   Working revision:1.4 Thu Nov 14 16:06:49 2002
   Repository revision: 1.4 /tmp/cvstest/test/foo,v
   Sticky Tag:  (none)
   Sticky Date: (none)
   Sticky Options:  (none)

-Larry Jones

It's going to be a long year. -- Calvin


___
Info-cvs mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/info-cvs



Re: Retrieving deleted file from the Attic

2002-11-14 Thread Eric Siegerman
On Wed, Nov 13, 2002 at 04:59:49PM -0800, Jason Yeung wrote:
 I was wondering if it's possible to recover a file that is in the Attic
 directory?

cvs update -j1.4 -j1.3 foo.c# 1.4 is the deleted rev.; 1.3 is the one
# preceding it.  The odd-looking order of the
# -j's is intentional, and important.
cvs commit

--

|  | /\
|-_|/ Eric Siegerman, Toronto, Ont.[EMAIL PROTECTED]
|  |  /
Just Say No to the faceless cannonfodder stereotype.
- http://www.ainurin.net/ (an Orc site)


___
Info-cvs mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/info-cvs



Retrieving deleted file from the Attic

2002-11-13 Thread Jason Yeung
Hi,

I was wondering if it's possible to recover a file that is in the Attic
directory? When you remove a file (and committed), the file gets copied to
the Attic directory. For all purposes, it's removed from the repository.

Jason




___
Info-cvs mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/info-cvs