2.10. Removing FilesTo remove a file from the repository, first remove the file from the sandbox directory, then run the following command from the sandbox directory that contained the file: cvs remove filename The deletion does not take effect until the next cvs commit command is run; the file remains in the repository until then. Example 2-20 shows a deletion, and Figure 2-11 shows the same deletion in gCVS. After the cvs commit is run, CVS doesn't remove the file entirely; it puts it in a special subdirectory in the repository called Attic. This step saves the file history and enables the file to be returned to the repository later. Example 2-20. Removing a file
Figure 2-11. Removing a file with gCVSCVS opens an editor so you can record the reason for the file deletion, as it does when you commit changes. CVS does not remove directories from the repository, because doing so would break the change tracking. Use the -P flag to cvs checkout and cvs update to avoid empty directories in your sandbox. |