bug-cvs
[Top][All Lists]
Advanced

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

Re: Attic cleanup


From: Paul Edwards
Subject: Re: Attic cleanup
Date: Tue, 10 Jun 2003 13:24:13 GMT

"Derek Robert Price" <derek@ximbiot.com> wrote in message 
news:mailman.7590.1055170783.21513.bug-cvs@gnu.org...
> That's easy, Mark.  Just `test -d $CVSROOT_DIRNAME/modulename/Attic'.
>
> As long as the test -d was in place, I'd trust user's to run sanity.sh
> on the appropriate filesystems as they found necessary.  Also, Paul, if
> you'd like to send a patch with test cases testing various CVS commands
> when the Attic is empty, I'd likely commit that.  Of course, if the
> Attic went away when empty, I suppose only the test that it was deleted
> would be necessary.  This would be less code in the test suite.

Here's a diff against cvs1-11-6.  Not sure if you also want a
comment.  "/* remove Attic directory if no files remain */".

Index: ChangeLog
===================================================================
RCS file: /development/repository/ccvs/ChangeLog,v
retrieving revision 1.1.1.7
diff -c -r1.1.1.7 ChangeLog
*** ChangeLog   27 May 2003 10:00:06 -0000      1.1.1.7
--- ChangeLog   10 Jun 2003 11:07:19 -0000
***************
*** 1,3 ****
--- 1,8 ----
+ 2003-06-10  Paul Edwards
+
+       * rcs.c: remove empty Attic
+       * sanity.sh: added attic-1
+
  2003-05-25  Derek Price  <derek@ximbiot.com>

        * configure.in: Update CVS version to 1.11.6.
Index: src/rcs.c
===================================================================
RCS file: /development/repository/ccvs/src/rcs.c,v
retrieving revision 1.1.1.7
diff -c -r1.1.1.7 rcs.c
*** src/rcs.c   27 May 2003 10:03:15 -0000      1.1.1.7
--- src/rcs.c   10 Jun 2003 10:50:59 -0000
***************
*** 626,631 ****
--- 626,633 ----
            free (newpath);
            return 1;
        }
+       *p = '\0';
+       rmdir (rcs->path);
      }

      free (rcs->path);
Index: src/sanity.sh
===================================================================
RCS file: /development/repository/ccvs/src/sanity.sh,v
retrieving revision 1.1.1.6
diff -c -r1.1.1.6 sanity.sh
*** src/sanity.sh       27 May 2003 10:04:20 -0000      1.1.1.6
--- src/sanity.sh       10 Jun 2003 11:04:09 -0000
***************
*** 3890,3895 ****
--- 3890,3917 ----
                rm -rf ${CVSROOT_DIRNAME}/first-dir
                ;;

+     attic)
+         # Test Attic
+         mkdir ${CVSROOT_DIRNAME}/aaa
+         ${testcvs} checkout aaa >/dev/null 2>&1
+         cd aaa
+         echo xxx >one.c
+         ${testcvs} add one.c >/dev/null 2>&1
+         ${testcvs} commit -m "." one.c >/dev/null 2>&1
+         ${testcvs} tag -b aaatag one.c >/dev/null 2>&1
+         ${testcvs} update -r aaatag >/dev/null 2>&1
+         cp one.c two.c
+         ${testcvs} add two.c >/dev/null 2>&1
+         ${testcvs} commit -m "." two.c >/dev/null 2>&1
+         ${testcvs} update -A >/dev/null 2>&1
+         ${testcvs} update -j aaatag two.c >/dev/null 2>&1
+         ${testcvs} commit -m "." two.c >/dev/null 2>&1
+         dotest_fail attic-1 "test -d ${CVSROOT_DIRNAME}/aaa/Attic"
+         cd ..
+         rm -fr aaa
+         rm -fr ${CVSROOT_DIRNAME}/aaa
+         ;;
+
        rdiff)
                # Test rdiff
                # XXX for now this is just the most essential test...





reply via email to

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